android_kernel_oneplus_msm8998/arch
Nicholas Piggin b5145f8b35 powerpc/64s: Fix compiler store ordering to SLB shadow area
[ Upstream commit 926bc2f100c24d4842b3064b5af44ae964c1d81c ]

The stores to update the SLB shadow area must be made as they appear
in the C code, so that the hypervisor does not see an entry with
mismatched vsid and esid. Use WRITE_ONCE for this.

GCC has been observed to elide the first store to esid in the update,
which means that if the hypervisor interrupts the guest after storing
to vsid, it could see an entry with old esid and new vsid, which may
possibly result in memory corruption.

Signed-off-by: Nicholas Piggin <npiggin@gmail.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Signed-off-by: Sasha Levin <alexander.levin@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-08-06 16:24:31 +02:00
..
alpha locking/xchg/alpha: Fix xchg() and cmpxchg() memory ordering bugs 2018-05-30 07:49:01 +02:00
arc ARC: mm: allow mprotect to make stack mappings executable 2018-07-25 10:18:16 +02:00
arm ARM: fix put_user() for gcc-8 2018-07-28 07:45:05 +02:00
arm64 arm64: lse: Add early clobbers to some input/output asm operands 2018-06-06 16:46:20 +02:00
avr32 avr32: off by one in at32_init_pio() 2016-10-07 15:23:45 +02:00
blackfin pinctrl: adi2: Fix Kconfig build problem 2017-12-20 10:05:00 +01:00
c6x c6x/ptrace: Remove useless PTRACE_SETREGSET implementation 2017-03-31 09:49:53 +02:00
cris cris: Only build flash rescue image if CONFIG_ETRAX_AXISFLASHMAP is selected 2017-01-12 11:22:48 +01:00
frv futex: Remove duplicated code and fix undefined behaviour 2018-05-26 08:48:50 +02:00
h8300 h8300/ptrace: Fix incorrect register transfer count 2017-03-31 09:49:53 +02:00
hexagon futex: Remove duplicated code and fix undefined behaviour 2018-05-26 08:48:50 +02:00
ia64 futex: Remove duplicated code and fix undefined behaviour 2018-05-26 08:48:50 +02:00
m32r m32r: fix __get_user() 2016-09-24 10:07:43 +02:00
m68k m68k/mm: Adjust VM area to be unmapped by gap size for __iounmap() 2018-07-03 11:21:26 +02:00
metag metag/uaccess: Check access_ok in strncpy_from_user 2017-05-25 14:30:16 +02:00
microblaze futex: Remove duplicated code and fix undefined behaviour 2018-05-26 08:48:50 +02:00
mips MIPS: Fix off-by-one in pci_resource_to_user() 2018-08-06 16:24:29 +02:00
mn10300 mn10300/misalignment: Use SIGSEGV SEGV_MAPERR to report a failed user copy 2018-02-16 20:09:47 +01:00
nios2 nios2: reserve boot memory for device tree 2017-04-12 12:38:34 +02:00
openrisc signal/openrisc: Fix do_unaligned_access to send the proper signal 2018-02-16 20:09:46 +01:00
parisc futex: Remove duplicated code and fix undefined behaviour 2018-05-26 08:48:50 +02:00
powerpc powerpc/64s: Fix compiler store ordering to SLB shadow area 2018-08-06 16:24:31 +02:00
s390 s390: Correct register corruption in critical section cleanup 2018-07-11 16:03:48 +02:00
score score: fix copy_from_user() and friends 2016-09-24 10:07:44 +02:00
sh sh: New gcc support 2018-06-06 16:46:20 +02:00
sparc sparc64: Fix build warnings with gcc 7. 2018-06-06 16:46:23 +02:00
tile futex: Remove duplicated code and fix undefined behaviour 2018-05-26 08:48:50 +02:00
um um: Use POSIX ucontext_t instead of struct ucontext 2018-04-24 09:32:08 +02:00
unicore32 pwm: Changes for v4.4-rc1 2015-11-11 09:16:10 -08:00
x86 x86/cpu: Re-apply forced caps every time CPU caps are re-read 2018-07-25 10:18:31 +02:00
xtensa signal/xtensa: Consistenly use SIGBUS in do_unaligned_user 2018-07-03 11:21:26 +02:00
.gitignore
Kconfig