On Thu, 19 May 2016, Jason Low wrote:
The mutex owner can get read and written to without the wait_lock. Use WRITE_ONCE when setting and clearing the owner field in order to avoid optimizations such as store tearing. This avoids situations where the owner field gets written to with multiple stores and another thread could concurrently read and use a partially written owner value.
Right, I also ran into this with rtmutexes when avoiding the schedule() and the spin on owner thingie.
Signed-off-by: Jason Low <[email protected]>
Acked-by: Davidlohr Bueso <[email protected]>

