Skip to content
Commit 9efd8426 authored by Andrey Albershteyn's avatar Andrey Albershteyn Committed by Greg Kroah-Hartman
Browse files

xfs: reset XFS_ATTR_INCOMPLETE filter on node removal

commit 82ef1a53 upstream.

In XFS_DAS_NODE_REMOVE_ATTR case, xfs_attr_mode_remove_attr() sets
filter to XFS_ATTR_INCOMPLETE. The filter is then reset in
xfs_attr_complete_op() if XFS_DA_OP_REPLACE operation is performed.

The filter is not reset though if XFS just removes the attribute
(args->value == NULL) with xfs_attr_defer_remove(). attr code goes
to XFS_DAS_DONE state.

Fix this by always resetting XFS_ATTR_INCOMPLETE filter. The replace
operation already resets this filter in anyway and others are
completed at this step hence don't need it.

Fixes: fdaf1bb3

 ("xfs: ATTR_REPLACE algorithm with LARP enabled needs rework")
Signed-off-by: default avatarAndrey Albershteyn <aalbersh@redhat.com>
Reviewed-by: default avatarChristoph Hellwig <hch@lst.de>
Signed-off-by: default avatarChandan Babu R <chandanbabu@kernel.org>
Signed-off-by: default avatarCatherine Hoang <catherine.hoang@oracle.com>
Acked-by: default avatarDarrick J. Wong <djwong@kernel.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 69252ab1
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment