kprobes: add (un)register_kretprobes for batch registration
[firefly-linux-kernel-4.4.55.git] / fs / namespace.c
index c807b8d5f89176aba3c927839a89a3fd51fa5b35..f48f98110c30aefaa114ff0f15c0b7cece3f938d 100644 (file)
@@ -850,8 +850,13 @@ static int show_mountinfo(struct seq_file *m, void *v)
        /* Tagged fields ("foo:X" or "bar") */
        if (IS_MNT_SHARED(mnt))
                seq_printf(m, " shared:%i", mnt->mnt_group_id);
-       if (IS_MNT_SLAVE(mnt))
-               seq_printf(m, " master:%i", mnt->mnt_master->mnt_group_id);
+       if (IS_MNT_SLAVE(mnt)) {
+               int master = mnt->mnt_master->mnt_group_id;
+               int dom = get_dominating_id(mnt, &p->root);
+               seq_printf(m, " master:%i", master);
+               if (dom && dom != master)
+                       seq_printf(m, " propagate_from:%i", dom);
+       }
        if (IS_MNT_UNBINDABLE(mnt))
                seq_puts(m, " unbindable");
 
@@ -1056,10 +1061,11 @@ static int do_umount(struct vfsmount *mnt, int flags)
         * about for the moment.
         */
 
-       lock_kernel();
-       if (sb->s_op->umount_begin)
-               sb->s_op->umount_begin(mnt, flags);
-       unlock_kernel();
+       if (flags & MNT_FORCE && sb->s_op->umount_begin) {
+               lock_kernel();
+               sb->s_op->umount_begin(sb);
+               unlock_kernel();
+       }
 
        /*
         * No sense to grab the lock for this test, but test itself looks