[PATCH] mnt_expire is protected by namespace_sem, no need for vfsmount_lock

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>

Al Viro 6758f953 c35038be

+2 -9
+2 -9
fs/namespace.c
··· 262 262 /* stick the duplicate mount on the same expiry list 263 263 * as the original if that was on one */ 264 264 if (flag & CL_EXPIRE) { 265 - spin_lock(&vfsmount_lock); 266 265 if (!list_empty(&old->mnt_expire)) 267 266 list_add(&mnt->mnt_expire, &old->mnt_expire); 268 - spin_unlock(&vfsmount_lock); 269 267 } 270 268 } 271 269 return mnt; ··· 1125 1127 if (err) 1126 1128 goto out1; 1127 1129 1128 - spin_lock(&vfsmount_lock); 1129 1130 /* if the mount is moved, it should no longer be expire 1130 1131 * automatically */ 1131 1132 list_del_init(&old_nd.path.mnt->mnt_expire); 1132 - spin_unlock(&vfsmount_lock); 1133 1133 out1: 1134 1134 mutex_unlock(&nd->path.dentry->d_inode->i_mutex); 1135 1135 out: ··· 1194 1198 if ((err = graft_tree(newmnt, nd))) 1195 1199 goto unlock; 1196 1200 1197 - if (fslist) { 1198 - /* add to the specified expiration list */ 1199 - spin_lock(&vfsmount_lock); 1201 + if (fslist) /* add to the specified expiration list */ 1200 1202 list_add_tail(&newmnt->mnt_expire, fslist); 1201 - spin_unlock(&vfsmount_lock); 1202 - } 1203 + 1203 1204 up_write(&namespace_sem); 1204 1205 return 0; 1205 1206