[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+55aFzX6uyw7S88_axt3b0nkGK0BtFQw-3tKzJrsCfLBVkMdw@mail.gmail.com>
Date: Mon, 20 Apr 2015 09:04:20 -0700
From: Linus Torvalds <torvalds@...ux-foundation.org>
To: Davidlohr Bueso <dave@...olabs.net>
Cc: Peter Zijlstra <peterz@...radead.org>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>,
Sebastian Andrzej Siewior <bigeasy@...utronix.de>,
Chris Mason <clm@...com>, Steven Rostedt <rostedt@...dmis.org>,
fredrik.markstrom@...driver.com,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 2/2] futex: lockless wakeups
On Sun, Apr 19, 2015 at 12:17 PM, Davidlohr Bueso <dave@...olabs.net> wrote:
>
> Naturally, this can cause spurious wakeups. However there is core code
> that cannot handle them afaict, and furthermore tglx does have the point
> that other events can already trigger them anyway.
Indeed. We need to make this *very* explicit. We have absolutely
_always_ had spurious wakeups. The semaphore code does it today, other
code has done it historically. Nobody should ever expect that there si
only one unique wakeup source. Anybody who sleeps on a condition needs
to re-check the condition rather than assume that "because I was woken
up the condition must now be true".
Linus
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists