Re: [PATCH] block: insert a general SMP memory barrier before wake_up_bit()

From: peterz
Date: Thu Aug 13 2020 - 07:42:02 EST


On Thu, Aug 13, 2020 at 08:31:15AM +0100, Christoph Hellwig wrote:
> On Thu, Aug 13, 2020 at 10:44:38AM +0800, Jacob Wen wrote:
> > wake_up_bit() uses waitqueue_active() that needs the explicit smp_mb().
>
> Sounds like the barrier should go into wake_up_bit then..

Oh, thanks for reminding me..

https://lkml.kernel.org/r/20190624165012.GH3436@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

I'll try and get back to that.