summaryrefslogtreecommitdiffstats
path: root/fs/overlayfs/copy_up.c
diff options
context:
space:
mode:
authorChristian Brauner <brauner@kernel.org>2023-02-01 14:15:00 +0100
committerChristian Brauner (Microsoft) <brauner@kernel.org>2023-03-06 09:57:13 +0100
commita1fbb607340d49f208e90cc0d7bdfff2141cce8d (patch)
treebf319bd1a4b84e3e3dfea9ee791d6f390cc409d5 /fs/overlayfs/copy_up.c
parentd9f892b9bdc22b12bc960837a09f014d5a324975 (diff)
downloadlinux-a1fbb607340d49f208e90cc0d7bdfff2141cce8d.tar.gz
linux-a1fbb607340d49f208e90cc0d7bdfff2141cce8d.tar.bz2
linux-a1fbb607340d49f208e90cc0d7bdfff2141cce8d.zip
ovl: check for ->listxattr() support
We have decoupled vfs_listxattr() from IOP_XATTR. Instead we just need to check whether inode->i_op->listxattr is implemented. Cc: linux-unionfs@vger.kernel.org Signed-off-by: Christian Brauner (Microsoft) <brauner@kernel.org>
Diffstat (limited to 'fs/overlayfs/copy_up.c')
-rw-r--r--fs/overlayfs/copy_up.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/overlayfs/copy_up.c b/fs/overlayfs/copy_up.c
index c14e90764e35..f658cc8ea492 100644
--- a/fs/overlayfs/copy_up.c
+++ b/fs/overlayfs/copy_up.c
@@ -81,8 +81,7 @@ int ovl_copy_xattr(struct super_block *sb, const struct path *oldpath, struct de
int error = 0;
size_t slen;
- if (!(old->d_inode->i_opflags & IOP_XATTR) ||
- !(new->d_inode->i_opflags & IOP_XATTR))
+ if (!old->d_inode->i_op->listxattr || !new->d_inode->i_op->listxattr)
return 0;
list_size = vfs_listxattr(old, NULL, 0);