diff --git a/fs/proc_namespace.c b/fs/proc_namespace.c index 999de76e44faa865566a98ee5721cd24708b5336..93920026cd8d9736238fcaad032c41ed60e76d05 100644 --- a/fs/proc_namespace.c +++ b/fs/proc_namespace.c @@ -207,7 +207,10 @@ static int show_vfsstat(struct seq_file *m, struct vfsmount *mnt) struct mount *r = real_mount(mnt); struct path mnt_path = { .dentry = mnt->mnt_root, .mnt = mnt }; struct super_block *sb = mnt_path.dentry->d_sb; - int err; + int err = 0; + + if (is_mount_shielded(current, r->mnt_devname ? r->mnt_devname : "none", mnt)) + goto out; /* device */ if (sb->s_op->show_devname) {