Skip to content

Commit 44b58cd

Browse files
author
Al Viro
committed
do_move_mount(), vfs_move_mount(), do_move_mount_old(): constify struct path argument(s)
Reviewed-by: Christian Brauner <brauner@kernel.org> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
1 parent b42ffcd commit 44b58cd

1 file changed

Lines changed: 6 additions & 4 deletions

File tree

fs/namespace.c

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3566,8 +3566,9 @@ static inline bool may_use_mount(struct mount *mnt)
35663566
return check_anonymous_mnt(mnt);
35673567
}
35683568

3569-
static int do_move_mount(struct path *old_path,
3570-
struct path *new_path, enum mnt_tree_flags_t flags)
3569+
static int do_move_mount(const struct path *old_path,
3570+
const struct path *new_path,
3571+
enum mnt_tree_flags_t flags)
35713572
{
35723573
struct mount *old = real_mount(old_path->mnt);
35733574
int err;
@@ -3639,7 +3640,7 @@ static int do_move_mount(struct path *old_path,
36393640
return attach_recursive_mnt(old, &mp);
36403641
}
36413642

3642-
static int do_move_mount_old(struct path *path, const char *old_name)
3643+
static int do_move_mount_old(const struct path *path, const char *old_name)
36433644
{
36443645
struct path old_path;
36453646
int err;
@@ -4469,7 +4470,8 @@ SYSCALL_DEFINE3(fsmount, int, fs_fd, unsigned int, flags,
44694470
return ret;
44704471
}
44714472

4472-
static inline int vfs_move_mount(struct path *from_path, struct path *to_path,
4473+
static inline int vfs_move_mount(const struct path *from_path,
4474+
const struct path *to_path,
44734475
enum mnt_tree_flags_t mflags)
44744476
{
44754477
int ret;

0 commit comments

Comments
 (0)