diff options
author | Peter Zijlstra <peterz@infradead.org> | 2016-09-02 13:42:12 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2016-10-25 11:31:53 +0200 |
commit | 5bbd7e644378334700889fb762d5893985a7311f (patch) | |
tree | 4de0e1d4dcb783e6cb86ba234ff79f85ffab18a7 /lib | |
parent | 9d659ae14b545c4296e812c70493bfdc999b5c1c (diff) |
locking/mutex: Restructure wait loop
Doesn't really matter yet, but pull the HANDOFF and trylock out from
under the wait_lock.
The intention is to add an optimistic spin loop here, which requires
we do not hold the wait_lock, so shuffle code around in preparation.
Also clarify the purpose of taking the wait_lock in the wait loop, its
tempting to want to avoid it altogether, but the cancellation cases
need to to avoid losing wakeups.
Suggested-by: Waiman Long <waiman.long@hpe.com>
Tested-by: Jason Low <jason.low2@hpe.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: linux-kernel@vger.kernel.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'lib')
0 files changed, 0 insertions, 0 deletions