android_kernel_oneplus_msm8998/arch/xtensa/include
Max Filippov 1c11f153eb xtensa: fix futex_atomic_cmpxchg_inatomic
commit ca47480921587ae30417dd234a9f79af188e3666 upstream.

Return 0 if the operation was successful, not the userspace memory
value. Check that userspace value equals passed oldval, not itself.
Don't update *uval if the value wasn't read from userspace memory.

This fixes process hang due to infinite loop in futex_lock_pi.
It also fixes a bunch of glibc tests nptl/tst-mutexpi*.

Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-02-16 20:09:47 +01:00
..
asm xtensa: fix futex_atomic_cmpxchg_inatomic 2018-02-16 20:09:47 +01:00
uapi/asm mm: mlock: add mlock flags to enable VM_LOCKONFAULT usage 2015-11-05 19:34:48 -08:00