]> Git Repo - linux.git/commitdiff
Merge branch 'locking/urgent' into locking/core
authorThomas Gleixner <[email protected]>
Sat, 18 Dec 2021 09:57:03 +0000 (10:57 +0100)
committerThomas Gleixner <[email protected]>
Sat, 18 Dec 2021 09:57:03 +0000 (10:57 +0100)
Pick up the spin loop condition fix.

Signed-off-by: Thomas Gleixner <[email protected]>
1  2 
kernel/locking/rtmutex.c

diff --combined kernel/locking/rtmutex.c
index 0c1f2e3f019a32713f979dd3a2bbedb422d0df12,1f25a4d7de27329fb94b8f62c2eeb462c9656c2c..8555c4efe97c47ad52f3fc595463da05264d5388
@@@ -1103,11 -1103,8 +1103,11 @@@ static int __sched task_blocks_on_rt_mu
         * the other will detect the deadlock and return -EDEADLOCK,
         * which is wrong, as the other waiter is not in a deadlock
         * situation.
 +       *
 +       * Except for ww_mutex, in that case the chain walk must already deal
 +       * with spurious cycles, see the comments at [3] and [6].
         */
 -      if (owner == task)
 +      if (owner == task && !(build_ww_mutex() && ww_ctx))
                return -EDEADLK;
  
        raw_spin_lock(&task->pi_lock);
@@@ -1382,8 -1379,9 +1382,8 @@@ static bool rtmutex_spin_on_owner(struc
                 *    for CONFIG_PREEMPT_RCU=y)
                 *  - the VCPU on which owner runs is preempted
                 */
 -              if (!owner->on_cpu || need_resched() ||
 -                  !rt_mutex_waiter_is_top_waiter(lock, waiter) ||
 -                  vcpu_is_preempted(task_cpu(owner))) {
 +              if (!owner_on_cpu(owner) || need_resched() ||
-                   rt_mutex_waiter_is_top_waiter(lock, waiter)) {
++                  !rt_mutex_waiter_is_top_waiter(lock, waiter)) {
                        res = false;
                        break;
                }
This page took 0.062765 seconds and 4 git commands to generate.