On Sun, Jan 16, 2011 at 11:24 AM, Al Viro <v...@zeniv.linux.org.uk> wrote:
> On Sun, Jan 16, 2011 at 05:33:24AM +1100, Nick Piggin wrote:
>
>> Definitely agree.
>>
>> I'm on the road at the moment so would much appreciate if you can
>> cut the patch, but I could suggest something along the lines of:
>
> Easier than that, actually.  All it takes is (in #for-next, yet to
> be reordered in front of queue)
>        if (IS_ERR(dentry))
>                goto fail;
> +       if (nd->flags & LOOKUP_RCU)
> +               goto done2;
>        goto done;
> in the end of need_revalidate and
>                if (dentry->d_flags & DCACHE_OP_REVALIDATE)
>                        goto need_revalidate;
> +done2:
> in LOOKUP_RCU side of if ()...
>
> need_lookup does *not* suffer the same problem; you can't get there without
> dropping LOOKUP_RCU - the first thing it does is grabbing a mutex, for fsck
> sake...  And yes, you do drop RCU on all paths leading there.

Oh right it's do_revalidate, not d_revalidate, so it won't return NULL
still in rcu-walk :P

_______________________________________________
autofs mailing list
autofs@linux.kernel.org
http://linux.kernel.org/mailman/listinfo/autofs

Reply via email to