summaryrefslogtreecommitdiff
path: root/fs/internal.h
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2024-09-25 23:57:57 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2024-11-06 12:59:39 -0500
commit66d7ac6bdb07fbe69ca6971558a996ac04bbb643 (patch)
tree1286edd7e817562a1d50559d8be406eb5541eb9b /fs/internal.h
parenta10c4c5e01bdab617eaf3aaac9a96c22ddefa97e (diff)
replace do_setxattr() with saner helpers.
io_uring setxattr logics duplicates stuff from fs/xattr.c; provide saner helpers (filename_setxattr() and file_setxattr() resp.) and use them. NB: putname(ERR_PTR()) is a no-op Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/internal.h')
-rw-r--r--fs/internal.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/internal.h b/fs/internal.h
index b9f5ac4d39fc..be7c0da3bcec 100644
--- a/fs/internal.h
+++ b/fs/internal.h
@@ -285,10 +285,10 @@ ssize_t do_getxattr(struct mnt_idmap *idmap,
struct dentry *d,
struct kernel_xattr_ctx *ctx);
+int file_setxattr(struct file *file, struct kernel_xattr_ctx *ctx);
+int filename_setxattr(int dfd, struct filename *filename,
+ unsigned int lookup_flags, struct kernel_xattr_ctx *ctx);
int setxattr_copy(const char __user *name, struct kernel_xattr_ctx *ctx);
-int do_setxattr(struct mnt_idmap *idmap, struct dentry *dentry,
- struct kernel_xattr_ctx *ctx);
-
int import_xattr_name(struct xattr_name *kname, const char __user *name);
int may_write_xattr(struct mnt_idmap *idmap, struct inode *inode);