Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

ovl: remove ovl_lock_rename_workdir()

This function is unused since
Commit 833d2b3a072f ("Add start_renaming_two_dentries()")

Reviewed-by: Amir Goldstein <amir73il@gmail.com>
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: NeilBrown <neil@brown.name>
Link: https://patch.msgid.link/20260224222542.3458677-15-neilb@ownmail.net
Signed-off-by: Christian Brauner <brauner@kernel.org>

authored by

NeilBrown and committed by
Christian Brauner
54d7ea73 56c8fd73

-27
-2
fs/overlayfs/overlayfs.h
··· 569 569 bool ovl_need_index(struct dentry *dentry); 570 570 int ovl_nlink_start(struct dentry *dentry); 571 571 void ovl_nlink_end(struct dentry *dentry); 572 - int ovl_lock_rename_workdir(struct dentry *workdir, struct dentry *work, 573 - struct dentry *upperdir, struct dentry *upper); 574 572 int ovl_check_metacopy_xattr(struct ovl_fs *ofs, const struct path *path, 575 573 struct ovl_metacopy *data); 576 574 int ovl_set_metacopy_xattr(struct ovl_fs *ofs, struct dentry *d,
-25
fs/overlayfs/util.c
··· 1213 1213 ovl_inode_unlock(inode); 1214 1214 } 1215 1215 1216 - int ovl_lock_rename_workdir(struct dentry *workdir, struct dentry *work, 1217 - struct dentry *upperdir, struct dentry *upper) 1218 - { 1219 - struct dentry *trap; 1220 - 1221 - /* Workdir should not be subdir of upperdir and vice versa */ 1222 - trap = lock_rename(workdir, upperdir); 1223 - if (IS_ERR(trap)) 1224 - goto err; 1225 - if (trap) 1226 - goto err_unlock; 1227 - if (work && (work->d_parent != workdir || d_unhashed(work))) 1228 - goto err_unlock; 1229 - if (upper && (upper->d_parent != upperdir || d_unhashed(upper))) 1230 - goto err_unlock; 1231 - 1232 - return 0; 1233 - 1234 - err_unlock: 1235 - unlock_rename(workdir, upperdir); 1236 - err: 1237 - pr_err("failed to lock workdir+upperdir\n"); 1238 - return -EIO; 1239 - } 1240 - 1241 1216 /* 1242 1217 * err < 0, 0 if no metacopy xattr, metacopy data size if xattr found. 1243 1218 * an empty xattr returns OVL_METACOPY_MIN_SIZE to distinguish from no xattr value.