xfs
[Top] [All Lists]

Re: [PATCH 0/2] xfs: avoid overflow of attr3 leaf block headers with 64k

To: Brian Foster <bfoster@xxxxxxxxxx>
Subject: Re: [PATCH 0/2] xfs: avoid overflow of attr3 leaf block headers with 64k blocks
From: "Darrick J. Wong" <darrick.wong@xxxxxxxxxx>
Date: Wed, 25 Mar 2015 10:59:12 -0700
Cc: xfs@xxxxxxxxxxx
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <20150325165636.GA3436@xxxxxxxxxxxxxx>
References: <1424811024-24839-1-git-send-email-bfoster@xxxxxxxxxx> <20150325165636.GA3436@xxxxxxxxxxxxxx>
User-agent: Mutt/1.5.21 (2010-09-15)
On Wed, Mar 25, 2015 at 12:56:36PM -0400, Brian Foster wrote:
> On Tue, Feb 24, 2015 at 03:50:22PM -0500, Brian Foster wrote:
> > Hi all,
> > 
> > As it turns out, some of the leaf block codepaths other than xattr
> > addition look like they wouldn't work properly with an unaligned
> > firstused value as demonstrated in my previous patch:
> > 
> > http://oss.sgi.com/archives/xfs/2015-02/msg00479.html
> > 
> > Here's an alternate approach that handles the overflow in the header
> > conversion functions. It passes the basic tests so far, but more testing
> > is needed to make sure I've made valid assumptions. Thoughts?
> > 
> > FWIW, another approach could be to leak the last few bytes of the blocks
> > (e.g., max firstused at the last valid aligned offset and update freemap
> > size accordingly)...
> > 
> 
> ping?

Looks reasonable enough to me...

--D

> 
> > Brian
> > 
> > Brian Foster (2):
> >   xfs: pass attr geometry to attr leaf header conversion functions
> >   xfs: use larger in-core attr firstused field and detect overflow
> > 
> >  fs/xfs/libxfs/xfs_attr_leaf.c | 99 
> > +++++++++++++++++++++++++++++--------------
> >  fs/xfs/libxfs/xfs_attr_leaf.h |  6 ++-
> >  fs/xfs/libxfs/xfs_da_format.h |  8 +++-
> >  fs/xfs/xfs_attr_inactive.c    |  3 +-
> >  fs/xfs/xfs_attr_list.c        |  9 ++--
> >  5 files changed, 86 insertions(+), 39 deletions(-)
> > 
> > -- 
> > 1.9.3
> > 
> > _______________________________________________
> > xfs mailing list
> > xfs@xxxxxxxxxxx
> > http://oss.sgi.com/mailman/listinfo/xfs
> 
> _______________________________________________
> xfs mailing list
> xfs@xxxxxxxxxxx
> http://oss.sgi.com/mailman/listinfo/xfs

<Prev in Thread] Current Thread [Next in Thread>