[SRU][G][PATCH 0/1] Applications runing in QEMU/KVM get translation faults (LP: 1906255)
frank.heimes at canonical.com
frank.heimes at canonical.com
Wed Dec 2 20:33:27 UTC 2020
BugLink: https://bugs.launchpad.net/bugs/1906255
SRU Justification:
[Impact]
* The commit 0b0ed657fe "s390: remove critical section cleanup from entry.S" was introduced in kernel 5.8, but instigated a problem where FPU registers were not properly restored when entering the SIE (start interpretive execution) instruction.
* This leads to crashes of applications runnning inside KVM, as most of the programs in use nowdays are using FPU registers for backing of general register content.
* To fix this interrupts in load_fpu_regs() need to be disabled - otherwise an interrupt might come in after the registers are loaded, but before CIF_FPU is cleared in load_fpu_regs().
* When the interrupt returns, CIF_FPU will be cleared and the registers will never be restored.
[Fix]
* 1179f170b6f0af7bb0b3b7628136eaac450ddf31 1179f170b6f0 "s390: fix fpu restore in entry.S"
[Test Case]
* IBM Z or LinuxONE hardware with Ubuntu Server 20.10 installed.
* A KVM host needs to be setup as well as an KVM guest (use again 20.10).
* Run (ideally context switching) workload that makes use of FP instructions inside of the KVM guest.
* Monitor the health of the guest for crashes (logs).
[Regression Potential]
* Even if the code changes are quite overseeable, there is still a certain risk for regression, because:
* the modifications affect a critical part of the kernel (arch/s390/kernel/entry.S)
* affect the handling of the FPU registers
* and are always in use if KVM guests run
* So in worst case the changes may have an even bigger impact on FPU workloads in KVM guests
* and may not only crash in case of FPU usage, but also KVM in general.
* But the code is peurly s390x specific, hence affects IBM Z only,
* and it got already upstream accepted with v5.10-rc6
* and a test kernel (based on groovy master-next) was build for further testing.
[Other]
* The patch got upstream accepted with kernel v5.10-rc6, hence it will land sooner or later in Hirsute.
* It was initially planned to address groovy via 5.8 upstream stable update, and in fact the patch was already marked for this, but it didn't made it because 5.8 already reached it's EOL.
* Hence this SRU is submitted for groovy only.
Sven Schnelle (1):
s390: fix fpu restore in entry.S
arch/s390/kernel/asm-offsets.c | 10 +++++-----
arch/s390/kernel/entry.S | 2 ++
2 files changed, 7 insertions(+), 5 deletions(-)
--
2.25.1
More information about the kernel-team
mailing list