[Lustre-discuss] Looping in __d_lookup

Johann Lombardi johann at sun.com
Fri Jun 13 01:16:12 PDT 2008


On Wed, Jun 04, 2008 at 11:25:34AM +0200, Jakob Goldbach wrote:
> On Wed, 2008-06-04 at 12:10 +0300, Alex Lyashkov wrote:
> > > > 
> > > > --- ./lustre/llite/dcache.c.xxx	2007-09-27 16:04:08.000000000 +0400
> > > > +++ ./lustre/llite/dcache.c	2008-05-29 11:53:07.000000000 +0400
> > > > @@ -470,8 +470,8 @@ revalidate_finish:
> > > >          spin_lock(&dcache_lock);
> > > >          lock_dentry(de);
> > > >          __d_drop(de);
> > > > +        _d_rehash(de);
> > > >          unlock_dentry(de);
> > > > -        __d_rehash(de, 0);
> > > >          spin_unlock(&dcache_lock);
> > this will be deadlock with RHEL4 kernel.
> > 
> > cut from rhel4:
> > 
> > void __d_rehash(struct dentry * entry, int lock)
> > {
> 
> 
> But Im not calling __d_rehash.

Actually, _d_rehash() is not exported by the kernel, so I assume that you have
patched the kernel. At least, that's what I understand from the OpenVZ ticket:
http://bugzilla.openvz.org/show_bug.cgi?id=895#c27

Of course, we cannot do this for patchless clients :(

> Im calling _d_rehash which Andres suggest
> to be defined in lustre_pathcless_compat.h. Your cut is from kernel
> pathces anyway. My race happens on _patchless_ client.

As Yangsheng pointed out, the problem is that d_hash() cannot be used
by Lustre since the dentry_hashtable symbol is not exported.

Johann



More information about the lustre-discuss mailing list