diff options
-rw-r--r-- | fs/namespace.c | 4 | ||||
-rw-r--r-- | fs/pnode.c | 1 | ||||
-rw-r--r-- | include/linux/mount.h | 1 |
3 files changed, 5 insertions, 1 deletions
diff --git a/fs/namespace.c b/fs/namespace.c index 54cbef129f4a..d1708147eb45 100644 --- a/fs/namespace.c +++ b/fs/namespace.c | |||
@@ -1331,8 +1331,10 @@ static void umount_tree(struct mount *mnt, enum umount_tree_flags how) | |||
1331 | struct mount *p; | 1331 | struct mount *p; |
1332 | 1332 | ||
1333 | /* Gather the mounts to umount */ | 1333 | /* Gather the mounts to umount */ |
1334 | for (p = mnt; p; p = next_mnt(p, mnt)) | 1334 | for (p = mnt; p; p = next_mnt(p, mnt)) { |
1335 | p->mnt.mnt_flags |= MNT_UMOUNT; | ||
1335 | list_move(&p->mnt_list, &tmp_list); | 1336 | list_move(&p->mnt_list, &tmp_list); |
1337 | } | ||
1336 | 1338 | ||
1337 | /* Hide the mounts from lookup_mnt and mnt_mounts */ | 1339 | /* Hide the mounts from lookup_mnt and mnt_mounts */ |
1338 | list_for_each_entry(p, &tmp_list, mnt_list) { | 1340 | list_for_each_entry(p, &tmp_list, mnt_list) { |
diff --git a/fs/pnode.c b/fs/pnode.c index bf012af709dd..ac3aa0d43b90 100644 --- a/fs/pnode.c +++ b/fs/pnode.c | |||
@@ -384,6 +384,7 @@ static void __propagate_umount(struct mount *mnt) | |||
384 | if (child && list_empty(&child->mnt_mounts)) { | 384 | if (child && list_empty(&child->mnt_mounts)) { |
385 | list_del_init(&child->mnt_child); | 385 | list_del_init(&child->mnt_child); |
386 | hlist_del_init_rcu(&child->mnt_hash); | 386 | hlist_del_init_rcu(&child->mnt_hash); |
387 | child->mnt.mnt_flags |= MNT_UMOUNT; | ||
387 | list_move_tail(&child->mnt_list, &mnt->mnt_list); | 388 | list_move_tail(&child->mnt_list, &mnt->mnt_list); |
388 | } | 389 | } |
389 | } | 390 | } |
diff --git a/include/linux/mount.h b/include/linux/mount.h index c2c561dc0114..564beeec5d83 100644 --- a/include/linux/mount.h +++ b/include/linux/mount.h | |||
@@ -61,6 +61,7 @@ struct mnt_namespace; | |||
61 | #define MNT_DOOMED 0x1000000 | 61 | #define MNT_DOOMED 0x1000000 |
62 | #define MNT_SYNC_UMOUNT 0x2000000 | 62 | #define MNT_SYNC_UMOUNT 0x2000000 |
63 | #define MNT_MARKED 0x4000000 | 63 | #define MNT_MARKED 0x4000000 |
64 | #define MNT_UMOUNT 0x8000000 | ||
64 | 65 | ||
65 | struct vfsmount { | 66 | struct vfsmount { |
66 | struct dentry *mnt_root; /* root of the mounted tree */ | 67 | struct dentry *mnt_root; /* root of the mounted tree */ |