Re: vfs-scale, d_revalidate from nfsd

From: J. R. Okajima
Date: Fri Jan 14 2011 - 22:47:57 EST



Nick Piggin:
> Of course. I was discussing it with Miklos yesterday too, but haven't
> finished getting a proposal together.
>
> The main idea here would be to just pass in a flags parameter rather
> thank poking in nd to get the rcu-walk status. That would solve this
> problem and also avoid nd for most filesystems that don't care about
> it.

Let me make sure.
- add a flag parameter to ->d_revalidate. not remove the panameter nd.
- FS ->d_revalidate() will (probably) return -ECHILD when LOOKUP_RCU is
set.
Right?


Then how about the callers?
Current sequence is
- NFSD calls lookup_one_len
- __lookup_hash
- do_revalidate
- d_revalidate
{
status = dentry->d_op->d_revalidate(dentry, nd);
if (status == -ECHILD) {
;;;
status = dentry->d_op->d_revalidate(dentry, nd);
}
}

There will be no change in NFSD but VFS d_revalidate(), such like this?
VFS d_revalidate()
{
if (nd) {
dentry->d_op->d_revalidate(dentry, nd, nd->flags);
if (-ECHILD) {
dentry->d_op->d_revalidate(dentry, nd, nd->flags);
}
} else
return dentry->d_op->d_revalidate(dentry, NULL, 0);
}


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