From: Peter Zijlstra on
On Tue, 2010-03-23 at 22:15 +1100, Anton Blanchard wrote:
>
> It turns out commit c0f68c2fab4898bcc4671a8fb941f428856b4ad5 (generic-ipi:
> cleanup for generic_smp_call_function_interrupt()) is at fault. It removes
> locking from smp_call_function_many and in doing so creates a rather
> complicated race.

A rather simple question since my brain isn't quite ready processing the
content here..

Isn't reverting that one patch a simpler solution than adding all that
extra logic? If not, then the above statement seems false and we had a
bug even with that preempt_enable/disable() pair.

Just wondering.. :-)
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: Paul E. McKenney on
On Tue, Mar 23, 2010 at 01:26:43PM +0100, Peter Zijlstra wrote:
> On Tue, 2010-03-23 at 22:15 +1100, Anton Blanchard wrote:
> >
> > It turns out commit c0f68c2fab4898bcc4671a8fb941f428856b4ad5 (generic-ipi:
> > cleanup for generic_smp_call_function_interrupt()) is at fault. It removes
> > locking from smp_call_function_many and in doing so creates a rather
> > complicated race.
>
> A rather simple question since my brain isn't quite ready processing the
> content here..
>
> Isn't reverting that one patch a simpler solution than adding all that
> extra logic? If not, then the above statement seems false and we had a
> bug even with that preempt_enable/disable() pair.
>
> Just wondering.. :-)

If I understand correctly, if you want to fix it by reverting patches,
you have to revert back to simple locking (up to and including
54fdade1c3332391948ec43530c02c4794a38172). And I believe that the poor
performance of simple locking was whole reason for the series of patches.

Thanx, Paul
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: Peter Zijlstra on
On Tue, 2010-03-23 at 08:33 -0700, Paul E. McKenney wrote:
> On Tue, Mar 23, 2010 at 01:26:43PM +0100, Peter Zijlstra wrote:
> > On Tue, 2010-03-23 at 22:15 +1100, Anton Blanchard wrote:
> > >
> > > It turns out commit c0f68c2fab4898bcc4671a8fb941f428856b4ad5 (generic-ipi:
> > > cleanup for generic_smp_call_function_interrupt()) is at fault. It removes
> > > locking from smp_call_function_many and in doing so creates a rather
> > > complicated race.
> >
> > A rather simple question since my brain isn't quite ready processing the
> > content here..
> >
> > Isn't reverting that one patch a simpler solution than adding all that
> > extra logic? If not, then the above statement seems false and we had a
> > bug even with that preempt_enable/disable() pair.
> >
> > Just wondering.. :-)
>
> If I understand correctly, if you want to fix it by reverting patches,
> you have to revert back to simple locking (up to and including
> 54fdade1c3332391948ec43530c02c4794a38172). And I believe that the poor
> performance of simple locking was whole reason for the series of patches.

Right, then c0f68c2 did not in fact cause this bug..
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo(a)vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
From: Anton Blanchard on

Hi Peter,

> A rather simple question since my brain isn't quite ready processing the
> content here..

After working my way through that bug my brain wasn't in good shape
either because:

> Isn't reverting that one patch a simpler solution than adding all that
> extra logic? If not, then the above statement seems false and we had a
> bug even with that preempt_enable/disable() pair.

I screwed up the explanation :( The commit message that causes it is
54fdade1c3332391948ec43530c02c4794a38172 (generic-ipi: make struct
call_function_data lockless), and backing it out fixes the issue.

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