]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
attach_recursive_mnt(): unify the mnt_change_mountpoint() logics
authorAl Viro <viro@zeniv.linux.org.uk>
Sat, 26 Apr 2025 02:40:48 +0000 (22:40 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Sun, 29 Jun 2025 22:13:41 +0000 (18:13 -0400)
commit96f5d2e051653f2cfe9137c5d3c7794c358ffb03
treefaf8e6e42038ccbbe43bdb48dee728d656ad5921
parent7c6fb47b2b6c1ffcb1cae9372b9fcf269444487a
attach_recursive_mnt(): unify the mnt_change_mountpoint() logics

The logics used for tucking under existing mount differs for original
and copies; copies do a mount hash lookup to see if mountpoint to be is
already overmounted, while the original is told explicitly.

But the same logics that is used for copies works for the original,
at which point the only place where we get very close to eliminating
the need of passing 'beneath' flag to attach_recursive_mnt().

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/namespace.c