MIPS: Fix mips_atomic_set() with EVA
authorJames Hogan <james.hogan@imgtec.com>
Wed, 31 May 2017 15:19:49 +0000 (16:19 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 27 Jul 2017 22:08:03 +0000 (15:08 -0700)
commitf39f3b5d8260de549887f127ac5e99f0931b4990
tree5f3a1081a4f481583bbb72c14cfacb863b6609b5
parentdd2f83263dd8ecc4e325fe5f1aed5a930edbe643
MIPS: Fix mips_atomic_set() with EVA

commit 4915e1b043d6286928207b1f6968197b50407294 upstream.

EVA linked loads (LLE) and conditional stores (SCE) should be used on
EVA kernels for the MIPS_ATOMIC_SET operation of the sysmips system
call, or else the atomic set will apply to the kernel view of the
virtual address space (potentially unmapped on EVA kernels) rather than
the user view (TLB mapped).

Signed-off-by: James Hogan <james.hogan@imgtec.com>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/16151/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/mips/kernel/syscall.c