Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=429731b1553bacf9a331c260c317a28aaa878edb
Commit:     429731b1553bacf9a331c260c317a28aaa878edb
Parent:     db74ece990ea59a9ec9f00f8881026059ef5caf5
Author:     Jan Blunck <[EMAIL PROTECTED]>
AuthorDate: Thu Feb 14 19:34:31 2008 -0800
Committer:  Linus Torvalds <[EMAIL PROTECTED]>
CommitDate: Thu Feb 14 21:13:32 2008 -0800

    Remove path_release_on_umount()
    
    path_release_on_umount() should only be called from sys_umount(). I merged 
the
    function into sys_umount() instead of having in in namei.c.
    
    Signed-off-by: Jan Blunck <[EMAIL PROTECTED]>
    Acked-by: Christoph Hellwig <[EMAIL PROTECTED]>
    Cc: Al Viro <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
---
 fs/namei.c            |   10 ----------
 fs/namespace.c        |    4 +++-
 include/linux/namei.h |    1 -
 3 files changed, 3 insertions(+), 12 deletions(-)

diff --git a/fs/namei.c b/fs/namei.c
index 5270398..3ed4d75 100644
--- a/fs/namei.c
+++ b/fs/namei.c
@@ -368,16 +368,6 @@ void path_release(struct nameidata *nd)
        mntput(nd->mnt);
 }
 
-/*
- * umount() mustn't call path_release()/mntput() as that would clear
- * mnt_expiry_mark
- */
-void path_release_on_umount(struct nameidata *nd)
-{
-       dput(nd->dentry);
-       mntput_no_expire(nd->mnt);
-}
-
 /**
  * release_open_intent - free up open intent resources
  * @nd: pointer to nameidata
diff --git a/fs/namespace.c b/fs/namespace.c
index 63ced21..7937d30 100644
--- a/fs/namespace.c
+++ b/fs/namespace.c
@@ -690,7 +690,9 @@ asmlinkage long sys_umount(char __user * name, int flags)
 
        retval = do_umount(nd.mnt, flags);
 dput_and_out:
-       path_release_on_umount(&nd);
+       /* we mustn't call path_put() as that would clear mnt_expiry_mark */
+       dput(nd.dentry);
+       mntput_no_expire(nd.mnt);
 out:
        return retval;
 }
diff --git a/include/linux/namei.h b/include/linux/namei.h
index c13e411..307b1b3 100644
--- a/include/linux/namei.h
+++ b/include/linux/namei.h
@@ -72,7 +72,6 @@ extern int path_lookup(const char *, unsigned, struct 
nameidata *);
 extern int vfs_path_lookup(struct dentry *, struct vfsmount *,
                           const char *, unsigned int, struct nameidata *);
 extern void path_release(struct nameidata *);
-extern void path_release_on_umount(struct nameidata *);
 
 extern int __user_path_lookup_open(const char __user *, unsigned lookup_flags, 
struct nameidata *nd, int open_flags);
 extern int path_lookup_open(int dfd, const char *name, unsigned lookup_flags, 
struct nameidata *, int open_flags);
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to