Re: add_wait_queue() (unintentional?) behavior change in v4.13

From: Ingo Molnar
Date: Wed Dec 06 2017 - 11:43:57 EST



* Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx> wrote:

> On Wed, Nov 29, 2017 at 4:58 PM, Omar Sandoval <osandov@xxxxxxxxxxx> wrote:
> >
> > Note the change from __add_wait_queue() to
> > __add_wait_queue_entry_tail(). I'm assuming this was a typo since the
> > commit message doesn't mention any functional changes. This patch
> > restores the old behavior:
> > [...]
> > I didn't go through and audit callers of add_wait_queue(), but from a
> > quick code read this makes it so that non-exclusive waiters will not be
> > woken up if they are behind enough exclusive waiters, and I bet that'll
> > cause some bugs.
>
> This sounds right to me.
>
> Ingo?

Yeah, it's indeed unintended and it's a bug - I have applied the fix and will get
it to you ASAP.

Thanks,

Ingo