summaryrefslogtreecommitdiffstats
path: root/kernel/locking/rtmutex_common.h
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2016-12-02 11:13:44 +0100
committerIngo Molnar <mingo@kernel.org>2016-12-02 11:13:44 +0100
commit1b95b1a06cb27badb3e53329fb56af2a2113fd80 (patch)
treebbe52b10fde003833c980b0a30dd23b0e0855c87 /kernel/locking/rtmutex_common.h
parent3cded41794818d788aa1dc028ede4a1c1222d937 (diff)
parent1be5d4fa0af34fb7bafa205aeb59f5c7cc7a089d (diff)
Merge branch 'locking/urgent' into locking/core, to pick up dependent fixes
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'kernel/locking/rtmutex_common.h')
-rw-r--r--kernel/locking/rtmutex_common.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/kernel/locking/rtmutex_common.h b/kernel/locking/rtmutex_common.h
index 4f5f83c7d2d3..e317e1cbb3eb 100644
--- a/kernel/locking/rtmutex_common.h
+++ b/kernel/locking/rtmutex_common.h
@@ -75,8 +75,9 @@ task_top_pi_waiter(struct task_struct *p)
static inline struct task_struct *rt_mutex_owner(struct rt_mutex *lock)
{
- return (struct task_struct *)
- ((unsigned long)lock->owner & ~RT_MUTEX_OWNER_MASKALL);
+ unsigned long owner = (unsigned long) READ_ONCE(lock->owner);
+
+ return (struct task_struct *) (owner & ~RT_MUTEX_OWNER_MASKALL);
}
/*