]> www.infradead.org Git - users/willy/linux.git/commitdiff
locking/rtmutex: Fix misleading comment
authorPeter Zijlstra <peterz@infradead.org>
Tue, 8 Oct 2024 09:26:06 +0000 (11:26 +0200)
committerThomas Gleixner <tglx@linutronix.de>
Thu, 24 Oct 2024 21:03:30 +0000 (23:03 +0200)
Going through the RCU-boost and rtmutex code, I ran into this utterly
confusing comment. Fix it to avoid confusing future readers.

[ tglx: Wordsmithed the comment ]

Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Link: https://lore.kernel.org/all/20241008092606.GJ33184@noisy.programming.kicks-ass.net
kernel/locking/rtmutex_api.c

index a6974d04459301ed6435cdfac143365edafb22fe..7e79258feb279d44fdde7f2ba8278babc8384120 100644 (file)
@@ -175,10 +175,10 @@ bool __sched __rt_mutex_futex_unlock(struct rt_mutex_base *lock,
        }
 
        /*
-        * We've already deboosted, mark_wakeup_next_waiter() will
-        * retain preempt_disabled when we drop the wait_lock, to
-        * avoid inversion prior to the wakeup.  preempt_disable()
-        * therein pairs with rt_mutex_postunlock().
+        * mark_wakeup_next_waiter() deboosts and retains preemption
+        * disabled when dropping the wait_lock, to avoid inversion prior
+        * to the wakeup.  preempt_disable() therein pairs with the
+        * preempt_enable() in rt_mutex_postunlock().
         */
        mark_wakeup_next_waiter(wqh, lock);