Skip to contentSkip to conversation

namei fixes (18/19)

PATCH New Al Viro 1 participant 1 message May 19, 2005 VFS

lore
Share & tools
lore

Al Viro

author
#0 lore raw

PATCH 1/1 namei fixes (18/19)

(18/19)

Cosmetical cleanups - __follow_mount() calls in __link_path_walk() absorbed into do_lookup().

Obviously equivalent transformation.

----

fs/namei.c +1 -3
diff -urN RC12-rc4-17/fs/namei.c RC12-rc4-18/fs/namei.c
@@ -682,6 +682,7 @@
 done:
 	path->mnt = mnt;
 	path->dentry = dentry;
+	__follow_mount(path);
 	return 0;
 
 need_lookup:
@@ -789,8 +790,6 @@
 		err = do_lookup(nd, &this, &next);
 		if (err)
 			break;
-		/* Check mountpoints.. */
-		__follow_mount(&next);
 
 		err = -ENOENT;
 		inode = next.dentry->d_inode;
@@ -850,7 +849,6 @@
 		err = do_lookup(nd, &this, &next);
 		if (err)
 			break;
-		__follow_mount(&next);
 		inode = next.dentry->d_inode;
 		if ((lookup_flags & LOOKUP_FOLLOW)
 		    && inode && inode->i_op && inode->i_op->follow_link) {