aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--fs/xfs/libxfs/xfs_attr.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/fs/xfs/libxfs/xfs_attr.c b/fs/xfs/libxfs/xfs_attr.c
index 2815cfbbae70..e629bf51dc06 100644
--- a/fs/xfs/libxfs/xfs_attr.c
+++ b/fs/xfs/libxfs/xfs_attr.c
@@ -412,6 +412,14 @@ xfs_attr_set_iter(
if (error)
return error;
+ /*
+ * If addname was successful, and we dont need to alloc
+ * or remove anymore blks, we're done.
+ */
+ if (!args->rmtblkno &&
+ !(args->op_flags & XFS_DA_OP_RENAME))
+ return 0;
+
dac->dela_state = XFS_DAS_FOUND_NBLK;
}
trace_xfs_attr_set_iter_return(dac->dela_state, args->dp);