]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - kernel/futex.c
futex: Test for pi_mutex on fault in futex_wait_requeue_pi()
[karo-tx-linux.git] / kernel / futex.c
index e2b0fb9a0b3b3d0d5871ee37bf08618a6bf052e7..05018bfe21a7e6277656677ace6141e7a3effa34 100644 (file)
@@ -2370,7 +2370,7 @@ static int futex_wait_requeue_pi(u32 __user *uaddr, unsigned int flags,
         * fault, unlock the rt_mutex and return the fault to userspace.
         */
        if (ret == -EFAULT) {
-               if (rt_mutex_owner(pi_mutex) == current)
+               if (pi_mutex && rt_mutex_owner(pi_mutex) == current)
                        rt_mutex_unlock(pi_mutex);
        } else if (ret == -EINTR) {
                /*