Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=94777e09180b6249d455baa2dbe34cf630e0c033
Commit:     94777e09180b6249d455baa2dbe34cf630e0c033
Parent:     7d0c7d676cc066413e1583b5af9fba8011972d41
Author:     Eric W. Biederman <[EMAIL PROTECTED]>
AuthorDate: Mon Aug 20 21:36:30 2007 +0900
Committer:  Greg Kroah-Hartman <[EMAIL PROTECTED]>
CommitDate: Fri Oct 12 14:51:08 2007 -0700

    sysfs: In sysfs_lookup don't open code sysfs_find_dirent
    
    This is a small cleanup patch that makes the code just
    a little bit cleaner.
    
    Signed-off-by: Eric W. Biederman <[EMAIL PROTECTED]>
    Signed-off-by: Tejun Heo <[EMAIL PROTECTED]>
    Cc: Cornelia Huck <[EMAIL PROTECTED]>
    Signed-off-by: Greg Kroah-Hartman <[EMAIL PROTECTED]>
---
 fs/sysfs/dir.c |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/fs/sysfs/dir.c b/fs/sysfs/dir.c
index 7f4abe1..b72b42e 100644
--- a/fs/sysfs/dir.c
+++ b/fs/sysfs/dir.c
@@ -756,9 +756,7 @@ static struct dentry * sysfs_lookup(struct inode *dir, 
struct dentry *dentry,
 
        mutex_lock(&sysfs_mutex);
 
-       for (sd = parent_sd->s_children; sd; sd = sd->s_sibling)
-               if (sysfs_type(sd) && !strcmp(sd->s_name, dentry->d_name.name))
-                       break;
+       sd = sysfs_find_dirent(parent_sd, dentry->d_name.name);
 
        /* no such entry */
        if (!sd)
-
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