linux/arch
Heiko Carstens 183ea95f73 s390/vx: fix save/restore of fpu kernel context
[ Upstream commit e6b2dab418 ]

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-05 15:13:28 +01:00
..
alpha alpha: remove __init annotation from exported page_is_ram() 2023-08-16 18:22:03 +02:00
arc memblock: allow to specify flags with memblock_add_node() 2023-12-20 15:17:33 +01:00
arm ARM: OMAP2+: Fix null pointer dereference and memory leak in omap_soc_device_init 2024-01-05 15:13:27 +01:00
arm64 arm64: mm: Always make sw-dirty PTEs hw-dirty in pte_modify 2023-12-20 15:17:41 +01:00
csky kprobes: treewide: Cleanup the error messages for kprobes 2023-02-22 12:57:00 +01:00
h8300 h8300: Fix build errors from do_exit() to make_task_dead() transition 2023-02-01 08:27:21 +01:00
hexagon hexagon: Fix function name in die() 2023-02-01 08:27:20 +01:00
ia64 memblock: allow to specify flags with memblock_add_node() 2023-12-20 15:17:33 +01:00
m68k memblock: allow to specify flags with memblock_add_node() 2023-12-20 15:17:33 +01:00
microblaze exit: Add and use make_task_dead. 2023-02-01 08:27:20 +01:00
mips MIPS: Loongson64: Handle more memory types passed from firmware 2023-12-20 15:17:33 +01:00
nds32 exit: Add and use make_task_dead. 2023-02-01 08:27:20 +01:00
nios2 nios2: dts: Fix tse_mac "max-frame-size" property 2023-06-21 15:59:14 +02:00
openrisc openrisc: Properly store r31 to pt_regs on unhandled exceptions 2023-05-11 23:00:37 +09:00
parisc parisc: Drop the HP-UX ENOSYM and EREMOTERELEASE error codes 2023-12-08 08:48:02 +01:00
powerpc powerpc/ftrace: Fix stack teardown in ftrace_no_trace 2023-12-20 15:17:43 +01:00
riscv riscv: fix misaligned access handling of C.SWSP and C.SDSP 2023-12-13 18:36:41 +01:00
s390 s390/vx: fix save/restore of fpu kernel context 2024-01-05 15:13:28 +01:00
sh sh: bios: Revive earlyprintk support 2023-11-20 11:08:23 +01:00
sparc sparc32: fix a braino in fault handling in csum_and_copy_..._user() 2023-11-08 17:26:42 +01:00
um um: Fix hostaudio build errors 2023-09-19 12:22:49 +02:00
x86 perf/x86/uncore: Don't WARN_ON_ONCE() for a broken discovery table 2023-12-20 15:17:32 +01:00
xtensa xtensa: boot/lib: fix function prototypes 2023-10-06 13:18:14 +02:00
.gitignore
Kconfig init: Provide arch_cpu_finalize_init() 2023-08-08 19:58:30 +02:00