diff options
| author | Thomas Gleixner <[email protected]> | 2011-06-10 15:08:55 +0200 |
|---|---|---|
| committer | Ingo Molnar <[email protected]> | 2011-07-01 10:39:07 +0200 |
| commit | 307bf9803f25a8a3f53c1012110fb74e2f893eb0 (patch) | |
| tree | 72146cbf22ea0e7d36a0734cca9d46291c40ca89 /kernel/rtmutex-debug.c | |
| parent | 2a46dae38087e62dd5fb08a6dadf1407717ed13c (diff) | |
sched: Simplify mutex_spin_on_owner()
It does not make sense to rcu_read_lock/unlock() in every loop
iteration while spinning on the mutex.
Move the rcu protection outside the loop. Also simplify the
return path to always check for lock->owner == NULL which
meets the requirements of both owner changed and need_resched()
caused loop exits.
Signed-off-by: Thomas Gleixner <[email protected]>
Signed-off-by: Peter Zijlstra <[email protected]>
Cc: Linus Torvalds <[email protected]>
Cc: Andrew Morton <[email protected]>
Link: http://lkml.kernel.org/r/alpine.LFD.2.02.1106101458350.11814@ionos
Signed-off-by: Ingo Molnar <[email protected]>
Diffstat (limited to 'kernel/rtmutex-debug.c')
0 files changed, 0 insertions, 0 deletions