mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] use ->d_lock instead of dcache_lock in vfat_revalidate (2/6)
@ 2003-10-06 16:55 OGAWA Hirofumi
  0 siblings, 0 replies; only message in thread
From: OGAWA Hirofumi @ 2003-10-06 16:55 UTC (permalink / raw)
  To: Linus Torvalds; +Cc: linux-kernel

Hi,

This uses more fine granularity ->d_lock than ->dcache_lock for
->d_parent with d_move() race.

Please apply.

 linux-2.6.0-test6-hirofumi/fs/vfat/namei.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff -puN fs/vfat/namei.c~fat_d_lock-for-d_move fs/vfat/namei.c
--- linux-2.6.0-test6/fs/vfat/namei.c~fat_d_lock-for-d_move	2003-10-07 01:51:28.000000000 +0900
+++ linux-2.6.0-test6-hirofumi/fs/vfat/namei.c	2003-10-07 01:51:28.000000000 +0900
@@ -82,10 +82,10 @@ static int vfat_revalidate(struct dentry
 		 */
 		ret = 0;
 	else {
-		spin_lock(&dcache_lock);
+		spin_lock(&dentry->d_lock);
 		if (dentry->d_time != dentry->d_parent->d_inode->i_version)
 			ret = 0;
-		spin_unlock(&dcache_lock);
+		spin_unlock(&dentry->d_lock);
 	}
 	return ret;
 }

_

-- 
OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2003-10-06 16:56 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-10-06 16:55 [PATCH] use ->d_lock instead of dcache_lock in vfat_revalidate (2/6) OGAWA Hirofumi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®