lkml.org 
[lkml]   [2004]   [May]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: dentry bloat.


On Sat, 8 May 2004, Linus Torvalds wrote:
>
>
> On Sat, 8 May 2004, Andrew Morton wrote:
> >
> > I think we can simply take ->d_lock a bit earlier in __d_lookup. That will
> > serialise against d_move(), fixing the problem which you mention, and also
> > makes d_movecount go away.
>
> If you do that, RCU basically loses most of it's meaning.

Hmm.. Maybe I'm wrong.

In particular, it should be safe to at least do the name hash and parent
comparison without holding any lock (since even if they are invalidated by
a concurrent "move()" operation, doing the comparison is safe). By the
time those have matched, we are probably pretty safe in taking the lock,
since the likelihood of the other checks matching should be pretty high.

And yes, removing d_movecount would be ok by then, as long as we re-test
the parent inside d_lock (we don't need to re-test "hash", since if we
tested the full name inside the lock, the hash had better match too ;)

Comments?

Linus
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2009-11-18 23:46    [W:0.144 / U:0.024 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site