diff options
Diffstat (limited to 'kernel/futex.c')
| -rw-r--r-- | kernel/futex.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/kernel/futex.c b/kernel/futex.c index 414a30dbc6b6..c3eebcdac206 100644 --- a/kernel/futex.c +++ b/kernel/futex.c | |||
| @@ -1394,7 +1394,7 @@ static int wake_futex_pi(u32 __user *uaddr, u32 uval, struct futex_pi_state *pi_ | |||
| 1394 | { | 1394 | { |
| 1395 | u32 uninitialized_var(curval), newval; | 1395 | u32 uninitialized_var(curval), newval; |
| 1396 | struct task_struct *new_owner; | 1396 | struct task_struct *new_owner; |
| 1397 | bool deboost = false; | 1397 | bool postunlock = false; |
| 1398 | DEFINE_WAKE_Q(wake_q); | 1398 | DEFINE_WAKE_Q(wake_q); |
| 1399 | int ret = 0; | 1399 | int ret = 0; |
| 1400 | 1400 | ||
| @@ -1455,12 +1455,13 @@ static int wake_futex_pi(u32 __user *uaddr, u32 uval, struct futex_pi_state *pi_ | |||
| 1455 | /* | 1455 | /* |
| 1456 | * We've updated the uservalue, this unlock cannot fail. | 1456 | * We've updated the uservalue, this unlock cannot fail. |
| 1457 | */ | 1457 | */ |
| 1458 | deboost = __rt_mutex_futex_unlock(&pi_state->pi_mutex, &wake_q); | 1458 | postunlock = __rt_mutex_futex_unlock(&pi_state->pi_mutex, &wake_q); |
| 1459 | 1459 | ||
| 1460 | out_unlock: | 1460 | out_unlock: |
| 1461 | raw_spin_unlock_irq(&pi_state->pi_mutex.wait_lock); | 1461 | raw_spin_unlock_irq(&pi_state->pi_mutex.wait_lock); |
| 1462 | 1462 | ||
| 1463 | rt_mutex_postunlock(&wake_q, deboost); | 1463 | if (postunlock) |
| 1464 | rt_mutex_postunlock(&wake_q); | ||
| 1464 | 1465 | ||
| 1465 | return ret; | 1466 | return ret; |
| 1466 | } | 1467 | } |
