android_kernel_motorola_sm6225/arch
Heiko Carstens a40ad41b9f s390/vx: fix save/restore of fpu kernel context
[ Upstream commit e6b2dab41888332bf83f592131e7ea07756770a4 ]

The KERNEL_FPR mask only contains a flag for the first eight vector
registers. However floating point registers overlay parts of the first
sixteen vector registers.

This could lead to vector register corruption if a kernel fpu context uses
any of the vector registers 8 to 15 and is interrupted or calls a
KERNEL_FPR context. If that context uses also vector registers 8 to 15,
their contents will be corrupted on return.

Luckily this is currently not a real bug, since the kernel has only one
KERNEL_FPR user with s390_adjust_jiffies() and it is only using floating
point registers 0 to 2.

Fix this by using the correct bits for KERNEL_FPR.

Fixes: 7f79695cc1 ("s390/fpu: improve kernel_fpu_[begin|end]")
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Reviewed-by: Hendrik Brueckner <brueckner@linux.ibm.com>
Signed-off-by: Alexander Gordeev <agordeev@linux.ibm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-01-08 11:27:33 +01:00
..
alpha alpha: remove __init annotation from exported page_is_ram() 2023-08-16 18:13:01 +02:00
arc ARC: define ASM_NL and __ALIGN(_STR) outside #ifdef __ASSEMBLY__ guard 2023-08-11 11:45:11 +02:00
arm ARM: OMAP2+: Fix null pointer dereference and memory leak in omap_soc_device_init 2024-01-08 11:27:33 +01:00
arm64 arm64: dts: mediatek: mt8173-evb: Fix regulator-fixed node names 2024-01-08 11:27:32 +01:00
c6x
h8300 h8300: Fix build errors from do_exit() to make_task_dead() transition 2023-02-06 07:49:45 +01:00
hexagon hexagon: Fix function name in die() 2023-02-06 07:49:45 +01:00
ia64 treewide: Remove uninitialized_var() usage 2023-08-11 11:45:01 +02:00
m68k m68k: Fix invalid .section syntax 2023-09-23 10:47:57 +02:00
microblaze exit: Add and use make_task_dead. 2023-02-06 07:49:45 +01:00
mips MIPS: KVM: Fix a build warning about variable set but not used 2023-12-08 08:43:23 +01:00
nds32 exit: Add and use make_task_dead. 2023-02-06 07:49:45 +01:00
nios2 nios2: dts: Fix tse_mac "max-frame-size" property 2023-06-21 15:39:57 +02:00
openrisc openrisc: Properly store r31 to pt_regs on unhandled exceptions 2023-05-17 11:13:19 +02:00
parisc parisc/pgtable: Do not drop upper 5 address bits of physical address 2023-11-28 16:46:35 +00:00
powerpc powerpc/ftrace: Fix stack teardown in ftrace_no_trace 2023-12-20 15:38:04 +01:00
riscv riscv: Bump COMMAND_LINE_SIZE value to 1024 2023-04-05 11:15:36 +02:00
s390 s390/vx: fix save/restore of fpu kernel context 2024-01-08 11:27:33 +01:00
sh sh: bios: Revive earlyprintk support 2023-11-20 10:29:19 +01:00
sparc sparc: fix up arch_cpu_finalize_init() build breakage. 2023-08-16 18:12:59 +02:00
um um: Fix hostaudio build errors 2023-09-23 10:48:09 +02:00
unicore32
x86 x86/CPU/AMD: Check vendor in the AMD microcode callback 2023-12-13 17:42:20 +01:00
xtensa xtensa: ISS: fix call to split_if_spec 2023-08-11 11:45:23 +02:00
.gitignore
Kconfig init: Provide arch_cpu_finalize_init() 2023-08-08 19:49:17 +02:00