* Patch "mnt: fs_fully_visible test the proper mount for MNT_LOCKED" has been added to the 4.4-stable tree
@ 2016-07-11 22:47 gregkh
0 siblings, 0 replies; only message in thread
From: gregkh @ 2016-07-11 22:47 UTC (permalink / raw)
To: ebiederm, gregkh, seth.forshee; +Cc: stable, stable-commits
This is a note to let you know that I've just added the patch titled
mnt: fs_fully_visible test the proper mount for MNT_LOCKED
to the 4.4-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
mnt-fs_fully_visible-test-the-proper-mount-for-mnt_locked.patch
and it can be found in the queue-4.4 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
>From d71ed6c930ac7d8f88f3cef6624a7e826392d61f Mon Sep 17 00:00:00 2001
From: "Eric W. Biederman" <ebiederm@xmission.com>
Date: Fri, 27 May 2016 14:50:05 -0500
Subject: mnt: fs_fully_visible test the proper mount for MNT_LOCKED
From: Eric W. Biederman <ebiederm@xmission.com>
commit d71ed6c930ac7d8f88f3cef6624a7e826392d61f upstream.
MNT_LOCKED implies on a child mount implies the child is locked to the
parent. So while looping through the children the children should be
tested (not their parent).
Typically an unshare of a mount namespace locks all mounts together
making both the parent and the slave as locked but there are a few
corner cases where other things work.
Fixes: ceeb0e5d39fc ("vfs: Ignore unlocked mounts in fs_fully_visible")
Reported-by: Seth Forshee <seth.forshee@canonical.com>
Signed-off-by: "Eric W. Biederman" <ebiederm@xmission.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
fs/namespace.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/fs/namespace.c
+++ b/fs/namespace.c
@@ -3262,7 +3262,7 @@ static bool fs_fully_visible(struct file
list_for_each_entry(child, &mnt->mnt_mounts, mnt_child) {
struct inode *inode = child->mnt_mountpoint->d_inode;
/* Only worry about locked mounts */
- if (!(mnt_flags & MNT_LOCKED))
+ if (!(child->mnt.mnt_flags & MNT_LOCKED))
continue;
/* Is the directory permanetly empty? */
if (!is_empty_dir_inode(inode))
Patches currently in stable-queue which might be from ebiederm@xmission.com are
queue-4.4/mnt-fs_fully_visible-test-the-proper-mount-for-mnt_locked.patch
queue-4.4/mnt-if-fs_fully_visible-fails-call-put_filesystem.patch
queue-4.4/mnt-account-for-ms_rdonly-in-fs_fully_visible.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2016-07-11 23:22 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-11 22:47 Patch "mnt: fs_fully_visible test the proper mount for MNT_LOCKED" has been added to the 4.4-stable tree gregkh
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).