[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160518103011.GC3193@twins.programming.kicks-ass.net>
Date: Wed, 18 May 2016 12:30:11 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Waiman Long <Waiman.Long@....com>
Cc: Ingo Molnar <mingo@...hat.com>, linux-kernel@...r.kernel.org,
Davidlohr Bueso <dave@...olabs.net>,
Jason Low <jason.low2@...com>,
Dave Chinner <david@...morbit.com>,
Peter Hurley <peter@...leysoftware.com>,
"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>,
Scott J Norton <scott.norton@....com>,
Douglas Hatch <doug.hatch@....com>
Subject: Re: [PATCH v4 3/5] locking/rwsem: Don't wake up one's own task
On Tue, May 17, 2016 at 09:26:21PM -0400, Waiman Long wrote:
> As rwsem_down_read_failed() will queue itself and potentially call
> __rwsem_do_wake(sem, RWSEM_WAKE_ANY), it is possible that a reader
> will try to wake up its own task. This patch adds a check to make
> sure that this won't happen.
>
Yes, this is 'weird', but why are we fixing it at the cost of an extra
branch?
Powered by blists - more mailing lists