Re: vfs-scale, d_revalidate from nfsd
From: Nick Piggin
Date: Sat Jan 15 2011 - 13:35:09 EST
On Sat, Jan 15, 2011 at 2:47 PM, J. R. Okajima <hooanon05@xxxxxxxxxxx> wrote:
>
> 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);
> }
Yes that's the idea. I also want to pass a struct inode * parameter, to
facilitate rcu-walk implementations that want to check the inode
(such as fuse).
--
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/