From: Al Viro Date: Tue, 17 Sep 2013 01:19:20 +0000 (-0400) Subject: put_mnt_ns(): use drop_collected_mounts() X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=7b00ed6fe6321547b9d51f5bfb30e7b5932e6889;p=openwrt%2Fstaging%2Fblogic.git put_mnt_ns(): use drop_collected_mounts() ... rather than open-coding it Signed-off-by: Al Viro --- diff --git a/fs/namespace.c b/fs/namespace.c index da5c49483430..5918fc31a636 100644 --- a/fs/namespace.c +++ b/fs/namespace.c @@ -2802,11 +2802,7 @@ void put_mnt_ns(struct mnt_namespace *ns) { if (!atomic_dec_and_test(&ns->count)) return; - namespace_lock(); - br_write_lock(&vfsmount_lock); - umount_tree(ns->root, 0); - br_write_unlock(&vfsmount_lock); - namespace_unlock(); + drop_collected_mounts(&ns->root->mnt); free_mnt_ns(ns); }