summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorChristian Brauner <brauner@kernel.org>2026-03-06 12:24:19 +0300
committerChristian Brauner <brauner@kernel.org>2026-03-09 11:43:04 +0300
commit9c62536a958ffef246b6f7c01125ebac962158f8 (patch)
tree4ec25b06df03712f79604861e64ecea13ed8369b /include/linux
parent6de23f81a5e08be8fbf5e8d7e9febc72a5b5f27f (diff)
parent4d94ce88c77e74830a5b9d02ecb8286039ffa494 (diff)
downloadlinux-9c62536a958ffef246b6f7c01125ebac962158f8.tar.xz
Merge patch series "Further centralising of directory locking for name ops."
NeilBrown <neilb@ownmail.net> says: I am working towards changing the locking rules for name-operations: locking the name rather than the whole directory. The current part of this process is centralising all the locking so that it can be changed in one place. Recently "start_creating", "start_removing", "start_renaming" and related interaces were added which combine the locking and the lookup. At that time many callers were changed to use the new interfaces. However there are still an assortment of places out side of fs/namei.c where the directory is locked explictly, whether with inode_lock() or lock_rename() or similar. These were missed in the first pass for an assortment of uninteresting reasons. This series addresses the remaining places where explicit locking is used, and changes them to use the new interfaces, or otherwise removes the explicit locking. The biggest changes are in overlayfs. The other changes are quite simple, though maybe the cachefiles changes is the least simple of those. I'm running the --overlay tests in xfstests and nothing has popped yet. I'll continue with this and run some NFS tests too. * patches from https://patch.msgid.link/20260224222542.3458677-1-neilb@ownmail.net: VFS: unexport lock_rename(), lock_rename_child(), unlock_rename() ovl: remove ovl_lock_rename_workdir() ovl: use is_subdir() for testing if one thing is a subdir of another ovl: change ovl_create_real() to get a new lock when re-opening created file. ovl: pass name buffer to ovl_start_creating_temp() cachefiles: change cachefiles_bury_object to use start_renaming_dentry() ovl: Simplify ovl_lookup_real_one() VFS: make lookup_one_qstr_excl() static. nfsd: switch purge_old() to use start_removing_noperm() selinux: Use simple_start_creating() / simple_done_creating() Apparmor: Use simple_start_creating() / simple_done_creating() libfs: change simple_done_creating() to use end_creating() VFS: move the start_dirop() kerndoc comment to before start_dirop() fs/proc: Don't lock root inode when creating "self" and "thread-self" VFS: note error returns in documentation for various lookup functions Link: https://patch.msgid.link/20260224222542.3458677-1-neilb@ownmail.net Signed-off-by: Christian Brauner <brauner@kernel.org>
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/namei.h6
1 files changed, 0 insertions, 6 deletions
diff --git a/include/linux/namei.h b/include/linux/namei.h
index 58600cf234bc..2ad6dd9987b9 100644
--- a/include/linux/namei.h
+++ b/include/linux/namei.h
@@ -54,9 +54,6 @@ extern int path_pts(struct path *path);
extern int user_path_at(int, const char __user *, unsigned, struct path *);
-struct dentry *lookup_one_qstr_excl(const struct qstr *name,
- struct dentry *base,
- unsigned int flags);
extern int kern_path(const char *, unsigned, struct path *);
struct dentry *kern_path_parent(const char *name, struct path *parent);
@@ -168,9 +165,6 @@ extern int follow_down_one(struct path *);
extern int follow_down(struct path *path, unsigned int flags);
extern int follow_up(struct path *);
-extern struct dentry *lock_rename(struct dentry *, struct dentry *);
-extern struct dentry *lock_rename_child(struct dentry *, struct dentry *);
-extern void unlock_rename(struct dentry *, struct dentry *);
int start_renaming(struct renamedata *rd, int lookup_flags,
struct qstr *old_last, struct qstr *new_last);
int start_renaming_dentry(struct renamedata *rd, int lookup_flags,