linux-xfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Allison Collins <allison.henderson@oracle.com>
To: linux-xfs@vger.kernel.org
Subject: [PATCH v6 08/16] xfs: Factor out trans roll from xfs_attr3_leaf_setflag
Date: Sat, 18 Jan 2020 15:50:27 -0700	[thread overview]
Message-ID: <20200118225035.19503-9-allison.henderson@oracle.com> (raw)
In-Reply-To: <20200118225035.19503-1-allison.henderson@oracle.com>

New delayed allocation routines cannot be handling transactions so
factor them up into the calling functions

Signed-off-by: Allison Collins <allison.henderson@oracle.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Brian Foster <bfoster@redhat.com>
---
 fs/xfs/libxfs/xfs_attr.c      | 5 +++++
 fs/xfs/libxfs/xfs_attr_leaf.c | 5 +----
 2 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/fs/xfs/libxfs/xfs_attr.c b/fs/xfs/libxfs/xfs_attr.c
index c15361a..8ddea8d 100644
--- a/fs/xfs/libxfs/xfs_attr.c
+++ b/fs/xfs/libxfs/xfs_attr.c
@@ -1221,6 +1221,11 @@ xfs_attr_node_removename(
 		error = xfs_attr3_leaf_setflag(args);
 		if (error)
 			goto out;
+
+		error = xfs_trans_roll_inode(&args->trans, args->dp);
+		if (error)
+			goto out;
+
 		error = xfs_attr_rmtval_remove(args);
 		if (error)
 			goto out;
diff --git a/fs/xfs/libxfs/xfs_attr_leaf.c b/fs/xfs/libxfs/xfs_attr_leaf.c
index d691509..67339f0 100644
--- a/fs/xfs/libxfs/xfs_attr_leaf.c
+++ b/fs/xfs/libxfs/xfs_attr_leaf.c
@@ -2855,10 +2855,7 @@ xfs_attr3_leaf_setflag(
 			 XFS_DA_LOGRANGE(leaf, name_rmt, sizeof(*name_rmt)));
 	}
 
-	/*
-	 * Commit the flag value change and start the next trans in series.
-	 */
-	return xfs_trans_roll_inode(&args->trans, args->dp);
+	return 0;
 }
 
 /*
-- 
2.7.4


  parent reply	other threads:[~2020-01-18 22:50 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-18 22:50 [PATCH v6 00/16] xfs: Delay Ready Attributes Allison Collins
2020-01-18 22:50 ` [PATCH v6 01/16] xfs: Replace attribute parameters with struct xfs_name Allison Collins
2020-01-21 22:08   ` Darrick J. Wong
2020-01-18 22:50 ` [PATCH v6 02/16] xfs: Embed struct xfs_name in xfs_da_args Allison Collins
2020-01-21 22:15   ` Darrick J. Wong
2020-01-18 22:50 ` [PATCH v6 03/16] xfs: Add xfs_has_attr and subroutines Allison Collins
2020-01-21 22:48   ` Darrick J. Wong
2020-01-22  3:17     ` Allison Collins
2020-01-18 22:50 ` [PATCH v6 04/16] xfs: Factor out new helper functions xfs_attr_rmtval_set Allison Collins
2020-01-18 22:50 ` [PATCH v6 05/16] xfs: Factor out trans handling in xfs_attr3_leaf_flipflags Allison Collins
2020-01-18 22:50 ` [PATCH v6 06/16] xfs: Factor out xfs_attr_leaf_addname helper Allison Collins
2020-01-21 23:01   ` Darrick J. Wong
2020-01-22  4:15     ` Allison Collins
2020-01-18 22:50 ` [PATCH v6 07/16] xfs: Refactor xfs_attr_try_sf_addname Allison Collins
2020-01-21 23:07   ` Darrick J. Wong
2020-01-22  4:17     ` Allison Collins
2020-01-18 22:50 ` Allison Collins [this message]
2020-01-18 22:50 ` [PATCH v6 09/16] xfs: Factor out xfs_attr_rmtval_invalidate Allison Collins
2020-01-18 22:50 ` [PATCH v6 10/16] xfs: Factor out trans roll in xfs_attr3_leaf_clearflag Allison Collins
2020-01-18 22:50 ` [PATCH v6 11/16] xfs: Check for -ENOATTR or -EEXIST Allison Collins
2020-01-21 23:15   ` Darrick J. Wong
2020-01-22  4:29     ` Allison Collins
2020-01-25 16:41       ` Allison Collins
2020-01-26 22:28         ` Darrick J. Wong
2020-01-27  0:20           ` Allison Collins
2020-01-30 22:58             ` Darrick J. Wong
2020-01-18 22:50 ` [PATCH v6 12/16] xfs: Add helper function xfs_attr_init_unmapstate Allison Collins
2020-01-21 23:21   ` Darrick J. Wong
2020-01-22  5:05     ` Allison Collins
2020-01-18 22:50 ` [PATCH v6 13/16] xfs: Add helper function xfs_attr_rmtval_unmap Allison Collins
2020-01-21 23:24   ` Darrick J. Wong
2020-01-22  5:23     ` Allison Collins
2020-01-18 22:50 ` [PATCH v6 14/16] xfs: Simplify xfs_attr_set_args Allison Collins
2020-01-21 23:31   ` Darrick J. Wong
2020-01-22  7:39     ` Allison Collins
2020-01-18 22:50 ` [PATCH v6 15/16] xfs: Add delay ready attr remove routines Allison Collins
2020-01-22  0:02   ` Darrick J. Wong
2020-01-22  9:32     ` Allison Collins
2020-01-18 22:50 ` [PATCH v6 16/16] xfs: Add delay ready attr set routines Allison Collins
2020-01-22  0:12   ` Darrick J. Wong
2020-01-22 10:30     ` Allison Collins
2020-02-05 23:07       ` Allison Collins
2020-01-22 16:57     ` Allison Collins
2020-01-22 17:04       ` Allison Collins

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200118225035.19503-9-allison.henderson@oracle.com \
    --to=allison.henderson@oracle.com \
    --cc=linux-xfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).