public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: akpm@osdl.org
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] avoid lookup_hash usage in configfs
Date: Tue, 28 Jun 2005 13:36:01 +0200	[thread overview]
Message-ID: <20050628113601.GA1306@lst.de> (raw)

-mm specific addon to the same kind of patches I sent a few weeks ago


Index: linux-2.6.12/fs/configfs/dir.c
===================================================================
--- linux-2.6.12.orig/fs/configfs/dir.c	2005-06-27 21:12:19.000000000 +0200
+++ linux-2.6.12/fs/configfs/dir.c	2005-06-28 13:22:36.000000000 +0200
@@ -858,7 +858,7 @@
 
 	down(&parent->d_inode->i_sem);
 
-	new_dentry = configfs_get_dentry(parent, new_name);
+	new_dentry = lookup_one_len(new_name, parent, strlen(new_name));
 	if (!IS_ERR(new_dentry)) {
   		if (!new_dentry->d_inode) {
 			error = config_item_set_name(item, "%s", new_name);
Index: linux-2.6.12/fs/configfs/inode.c
===================================================================
--- linux-2.6.12.orig/fs/configfs/inode.c	2005-06-27 21:12:19.000000000 +0200
+++ linux-2.6.12/fs/configfs/inode.c	2005-06-28 13:22:43.000000000 +0200
@@ -98,16 +98,6 @@
 	return error;
 }
 
-struct dentry * configfs_get_dentry(struct dentry * parent, const char * name)
-{
-	struct qstr qstr;
-
-	qstr.name = name;
-	qstr.len = strlen(name);
-	qstr.hash = full_name_hash(name,qstr.len);
-	return lookup_hash(&qstr,parent);
-}
-
 /*
  * Get the name for corresponding element represented by the given configfs_dirent
  */

                 reply	other threads:[~2005-06-28 11:36 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050628113601.GA1306@lst.de \
    --to=hch@lst.de \
    --cc=akpm@osdl.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox