diff options
author | Marc Zyngier <maz@kernel.org> | 2025-07-20 11:22:29 +0100 |
---|---|---|
committer | Oliver Upton <oliver.upton@linux.dev> | 2025-07-21 09:34:57 -0700 |
commit | c6e35dff58d348c1a9489e9b3b62b3721e62631d (patch) | |
tree | ea0e0e661af438fbbcc4cc7af2c942dcc1f942b0 /tools/perf/scripts/python | |
parent | efa1368ba9f4b6e081c0fdd73245b0ba6ef75bda (diff) |
KVM: arm64: Check for SYSREGS_ON_CPU before accessing the CPU state
Mark Brown reports that since we commit to making exceptions
visible without the vcpu being loaded, the external abort selftest
fails.
Upon investigation, it turns out that the code that makes registers
affected by an exception visible to the guest is completely broken
on VHE, as we don't check whether the system registers are loaded
on the CPU at this point. We managed to get away with this so far,
but that's obviously as bad as it gets,
Add the required checksm and document the absolute need to check
for the SYSREGS_ON_CPU flag before calling into any of the
__vcpu_write_sys_reg_to_cpu()__vcpu_read_sys_reg_from_cpu() helpers.
Reported-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/18535df8-e647-4643-af9a-bb780af03a70@sirena.org.uk
Link: https://lore.kernel.org/r/20250720102229.179114-1-maz@kernel.org
Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions