lkml.org 
[lkml]   [2016]   [Jun]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: performance delta after VFS i_mutex=>i_rwsem conversion
On Mon, Jun 6, 2016 at 4:50 PM, Linus Torvalds
<torvalds@linux-foundation.org> wrote:
>
>
> And I do want to repeat that the patch is entirely untested. It compiles.
> I looked at the assembly it generated. It looks fine to me, but I might
> have had a brainfart and done something completely broken.

Dammit.

I did that whole dcache_emit_entry() thing because we need to do the
final target cursor move regardless, and dcache_emit_entry() will
always return with the spinlock held again.

But then I didn't actually fix the "return" to a "break".

So the "return 0" here:

> + /* This will drop and re-take the dentry lock .. */
> + if (!dcache_emit_entry(ctx, dentry, child))
> return 0;

is fatal and woudl return with the spinlock held. It *should* have
been a "break" to exit the readdir loop.

So the patch I sent out was indeed a terminal brainfart, but with that
fix to change that return to a "break" it *might* work.

Linus

\
 
 \ /
  Last update: 2016-06-07 02:21    [W:0.227 / U:0.208 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site