From add461325ec5bc39aa619a1bfcde7245e5f31ac7 Mon Sep 17 00:00:00 2001 From: Peter Zijlstra Date: Sun, 15 Aug 2021 23:28:58 +0200 Subject: locking/rtmutex: Extend the rtmutex core to support ww_mutex Add a ww acquire context pointer to the waiter and various functions and add the ww_mutex related invocations to the proper spots in the locking code, similar to the mutex based variant. Signed-off-by: Peter Zijlstra (Intel) Signed-off-by: Thomas Gleixner Signed-off-by: Peter Zijlstra (Intel) Signed-off-by: Ingo Molnar Link: https://lore.kernel.org/r/20210815211304.966139174@linutronix.de --- kernel/locking/rtmutex_common.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'kernel/locking/rtmutex_common.h') diff --git a/kernel/locking/rtmutex_common.h b/kernel/locking/rtmutex_common.h index ccf0e36d6c31..61256de5bd66 100644 --- a/kernel/locking/rtmutex_common.h +++ b/kernel/locking/rtmutex_common.h @@ -28,6 +28,7 @@ * @wake_state: Wakeup state to use (TASK_NORMAL or TASK_RTLOCK_WAIT) * @prio: Priority of the waiter * @deadline: Deadline of the waiter if applicable + * @ww_ctx: WW context pointer */ struct rt_mutex_waiter { struct rb_node tree_entry; @@ -37,6 +38,7 @@ struct rt_mutex_waiter { unsigned int wake_state; int prio; u64 deadline; + struct ww_acquire_ctx *ww_ctx; }; /** -- cgit v1.2.3