summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2013-01-24 18:16:00 -0500
committerAl Viro <viro@zeniv.linux.org.uk>2013-02-22 23:31:34 -0500
commite97cdc87be5804eb2922e169f6d81d3e214587ec (patch)
tree6d27d4923289071cf0b27850659ebb5fc8e0758e
parent21b9b073924aceb6b8d19c49f61daa86c0340e1a (diff)
downloadop-kernel-dev-e97cdc87be5804eb2922e169f6d81d3e214587ec.zip
op-kernel-dev-e97cdc87be5804eb2922e169f6d81d3e214587ec.tar.gz
lookup_fast: get rid of name argument
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r--fs/namei.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/namei.c b/fs/namei.c
index 5f6da6c..2782382 100644
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -1342,7 +1342,7 @@ static struct dentry *__lookup_hash(struct qstr *name,
* small and for now I'd prefer to have fast path as straight as possible.
* It _is_ time-critical.
*/
-static int lookup_fast(struct nameidata *nd, struct qstr *name,
+static int lookup_fast(struct nameidata *nd,
struct path *path, struct inode **inode)
{
struct vfsmount *mnt = nd->path.mnt;
@@ -1358,7 +1358,7 @@ static int lookup_fast(struct nameidata *nd, struct qstr *name,
*/
if (nd->flags & LOOKUP_RCU) {
unsigned seq;
- dentry = __d_lookup_rcu(parent, name, &seq, nd->inode);
+ dentry = __d_lookup_rcu(parent, &nd->last, &seq, nd->inode);
if (!dentry)
goto unlazy;
@@ -1400,7 +1400,7 @@ unlazy:
if (unlazy_walk(nd, dentry))
return -ECHILD;
} else {
- dentry = __d_lookup(parent, name);
+ dentry = __d_lookup(parent, &nd->last);
}
if (unlikely(!dentry))
@@ -1530,7 +1530,7 @@ static inline int walk_component(struct nameidata *nd, struct path *path,
*/
if (unlikely(nd->last_type != LAST_NORM))
return handle_dots(nd, nd->last_type);
- err = lookup_fast(nd, &nd->last, path, &inode);
+ err = lookup_fast(nd, path, &inode);
if (unlikely(err)) {
if (err < 0)
goto out_err;
@@ -2728,7 +2728,7 @@ static int do_last(struct nameidata *nd, struct path *path,
if (open_flag & O_PATH && !(nd->flags & LOOKUP_FOLLOW))
symlink_ok = true;
/* we _can_ be in RCU mode here */
- error = lookup_fast(nd, &nd->last, path, &inode);
+ error = lookup_fast(nd, path, &inode);
if (likely(!error))
goto finish_lookup;
OpenPOWER on IntegriCloud