Messages in this thread | | | Subject | Re: [PATCH 2/2] locking/rwsem: Use a return variable in rwsem_spin_on_owner() | From | Davidlohr Bueso <> | Date | Thu, 09 Apr 2015 12:59:37 -0700 |
| |
On Thu, 2015-04-09 at 12:43 -0700, Jason Low wrote: > So that looks more similar to how the original code was where the > rcu_read_lock() and rcu_read_unlock() was done inside the owner_running > helper function (though without the CONFIG_DEBUG_PAGEALLOC), before > commit 307bf9803f25 ("sched: Simplify mutex_spin_on_owner()") modified > it to be done outside the loop.
I think this is why Linus was mentioning the CONFIG_PREEMPT_RCU case as well, so taking and releasing the read lock in those cases in the loop would actually hurt more.
Thanks, Davidlohr
| |