diff options
author | Peter Zijlstra <[email protected]> | 2013-07-19 20:31:01 +0200 |
---|---|---|
committer | Ingo Molnar <[email protected]> | 2013-07-22 10:33:39 +0200 |
commit | 1e40c2edef2537f87f94d0baf80aeaeb7d51cc23 (patch) | |
tree | 3692ad447e3242ab2042edfd09d24107d5166652 /lib/memory-notifier-error-inject.c | |
parent | c4be9cb4f19cbd534a6c4c334cd48d8bb483e17a (diff) |
mutex: Fix/document access-once assumption in mutex_can_spin_on_owner()
mutex_can_spin_on_owner() is technically broken in that it would
in theory allow the compiler to load lock->owner twice, seeing a
pointer first time and a NULL pointer the second time.
Linus pointed out that a compiler has to be seriously broken to
not compile this correctly - but nevertheless this change
is correct as it will better document the implementation.
Signed-off-by: Peter Zijlstra <[email protected]>
Acked-by: Davidlohr Bueso <[email protected]>
Acked-by: Waiman Long <[email protected]>
Acked-by: Linus Torvalds <[email protected]>
Acked-by: Thomas Gleixner <[email protected]>
Acked-by: Rik van Riel <[email protected]>
Cc: Paul E. McKenney <[email protected]>
Cc: David Howells <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Ingo Molnar <[email protected]>
Diffstat (limited to 'lib/memory-notifier-error-inject.c')
0 files changed, 0 insertions, 0 deletions