On Sun, May 6, 2018 at 8:24 PM, Allison Henderson <allison.henderson@xxxxxxxxxx> wrote: > This patch adds two new log item types for setting or > removing attributes as deferred operations. The > xfs_attri_log_item logs an intent to set or remove an > attribute. The corresponding xfs_attrd_log_item holds > a reference to the xfs_attri_log_item and is freed once > the transaction is done. Both log items use a generic > xfs_attr_log_format structure that contains the attribute > name, value, flags, inode, and an op_flag that indicates > if the operations is a set or remove. > > At the moment, this feature will only be used by the parent > pointer patch set which uses attributes to store information > about an inodes parent. > > Signed-off-by: Allison Henderson <allison.henderson@xxxxxxxxxx> > --- [...] > +++ b/fs/xfs/xfs_trans_attr.c > @@ -0,0 +1,283 @@ > +/* > + * Copyright (c) 2017, Oracle Inc. > + * All Rights Reserved. > + * > + * This program is free software; you can redistribute it and/or > + * modify it under the terms of the GNU General Public License as > + * published by the Free Software Foundation. > + * > + * This program is distributed in the hope that it would be useful, > + * but WITHOUT ANY WARRANTY; without even the implied warranty of > + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the > + * GNU General Public License for more details. > + * > + * You should have received a copy of the GNU General Public License > + * along with this program; if not, write the Free Software Foundation Inc. > + */ > +#include "xfs.h" > +#include "xfs_fs.h" > +#include "xfs_shared.h" > +#include "xfs_format.h" > +#include "xfs_log_format.h" > +#include "xfs_trans_resv.h" > +#include "xfs_bit.h" > +#include "xfs_mount.h" > +#include "xfs_defer.h" > +#include "xfs_trans.h" > +#include "xfs_trans_priv.h" > +#include "xfs_attr_item.h" > +#include "xfs_alloc.h" > +#include "xfs_bmap.h" > +#include "xfs_trace.h" > +#include "libxfs/xfs_da_format.h" > +#include "xfs_da_btree.h" > +#include "xfs_attr.h" > +#include "xfs_inode.h" > +#include "xfs_icache.h" > +#include "xfs_quota.h" > + > +/* > + * This routine is called to allocate an "extent free done" > + * log item that will hold nextents worth of extents. The > + * caller must use all nextents extents, because we are not > + * flexible about this at all. > + */ Copy&paste error... Thanks, Amir. -- To unsubscribe from this list: send the line "unsubscribe linux-xfs" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html