acrn-kernel/arch
Heiko Carstens a759972d25 KVM: s390: fix sthyi error handling
[ Upstream commit 0c02cc576e ]

Commit 9fb6c9b3fe ("s390/sthyi: add cache to store hypervisor info")
added cache handling for store hypervisor info. This also changed the
possible return code for sthyi_fill().

Instead of only returning a condition code like the sthyi instruction would
do, it can now also return a negative error value (-ENOMEM). handle_styhi()
was not changed accordingly. In case of an error, the negative error value
would incorrectly injected into the guest PSW.

Add proper error handling to prevent this, and update the comment which
describes the possible return values of sthyi_fill().

Fixes: 9fb6c9b3fe ("s390/sthyi: add cache to store hypervisor info")
Reviewed-by: Christian Borntraeger <borntraeger@linux.ibm.com>
Link: https://lore.kernel.org/r/20230727182939.2050744-1-hca@linux.ibm.com
Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2023-08-11 12:08:11 +02:00
..
alpha init: Remove check_bugs() leftovers 2023-08-08 20:03:47 +02:00
arc ARC: define ASM_NL and __ALIGN(_STR) outside #ifdef __ASSEMBLY__ guard 2023-07-19 16:21:42 +02:00
arm ARM: cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:03:46 +02:00
arm64 arm64: dts: freescale: Fix VPU G2 clock 2023-08-11 12:08:10 +02:00
csky csky: fix up lock_mm_and_find_vma() conversion 2023-07-01 13:16:27 +02:00
hexagon mm/fault: convert remaining simple cases to lock_mm_and_find_vma() 2023-07-01 13:16:25 +02:00
ia64 ia64/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:03:46 +02:00
loongarch loongarch/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:03:46 +02:00
m68k m68k/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:03:46 +02:00
microblaze mm: always expand the stack with the mmap write lock held 2023-07-01 13:16:25 +02:00
mips mips/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:03:47 +02:00
nios2 mm/fault: convert remaining simple cases to lock_mm_and_find_vma() 2023-07-01 13:16:25 +02:00
openrisc mm: always expand the stack with the mmap write lock held 2023-07-01 13:16:25 +02:00
parisc init: Remove check_bugs() leftovers 2023-08-08 20:03:47 +02:00
powerpc word-at-a-time: use the same return type for has_zero regardless of endianness 2023-08-11 12:08:11 +02:00
riscv riscv: mm: fix truncation warning on RV32 2023-07-23 13:49:26 +02:00
s390 KVM: s390: fix sthyi error handling 2023-08-11 12:08:11 +02:00
sh sh/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:03:47 +02:00
sparc sparc/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:03:47 +02:00
um um/cpu: Switch to arch_cpu_finalize_init() 2023-08-08 20:03:47 +02:00
x86 x86: fix backwards merge of GDS/SRSO bit 2023-08-08 20:03:51 +02:00
xtensa init: Remove check_bugs() leftovers 2023-08-08 20:03:47 +02:00
.gitignore
Kconfig init: Provide arch_cpu_finalize_init() 2023-08-08 20:03:46 +02:00