diff options
| author | Jakub Kicinski <kuba@kernel.org> | 2025-06-12 10:08:24 -0700 |
|---|---|---|
| committer | Jakub Kicinski <kuba@kernel.org> | 2025-08-21 11:33:15 -0700 |
| commit | a9af709fda7edafa17e072bffe610d9e7ed7a5df (patch) | |
| tree | 11857f0522f37343677b6430ee8f9a4b1a9e420a /fs/pnode.c | |
| parent | selftests: net: fix memory leak in tls.c (diff) | |
| parent | Merge tag 'net-6.17-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/net... (diff) | |
| download | linux-a9af709fda7edafa17e072bffe610d9e7ed7a5df.tar.gz linux-a9af709fda7edafa17e072bffe610d9e7ed7a5df.zip | |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Cross-merge networking fixes after downstream PR (net-6.17-rc3).
No conflicts or adjacent changes.
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'fs/pnode.c')
| -rw-r--r-- | fs/pnode.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/fs/pnode.c b/fs/pnode.c index 81f7599bdac4..6f7d02f3fa98 100644 --- a/fs/pnode.c +++ b/fs/pnode.c @@ -111,7 +111,8 @@ void change_mnt_propagation(struct mount *mnt, int type) return; } if (IS_MNT_SHARED(mnt)) { - m = propagation_source(mnt); + if (type == MS_SLAVE || !hlist_empty(&mnt->mnt_slave_list)) + m = propagation_source(mnt); if (list_empty(&mnt->mnt_share)) { mnt_release_group_id(mnt); } else { @@ -637,10 +638,11 @@ void propagate_umount(struct list_head *set) } // now to_umount consists of all acceptable candidates - // deal with reparenting of remaining overmounts on those + // deal with reparenting of surviving overmounts on those list_for_each_entry(m, &to_umount, mnt_list) { - if (m->overmount) - reparent(m->overmount); + struct mount *over = m->overmount; + if (over && !will_be_unmounted(over)) + reparent(over); } // and fold them into the set |
