diff options
author | Oliver Upton <oupton@google.com> | 2022-02-03 20:41:54 +0300 |
---|---|---|
committer | Marc Zyngier <maz@kernel.org> | 2022-02-08 17:23:40 +0300 |
commit | e2ffceaae50883c5064641167078e5720fd8b74a (patch) | |
tree | 70f5aff4764a101d5d072ab84bdbb55b5c93f750 /net/batman-adv | |
parent | dfd42facf1e4ada021b939b4e19c935dcdd55566 (diff) | |
download | linux-e2ffceaae50883c5064641167078e5720fd8b74a.tar.xz |
KVM: arm64: Correctly treat writes to OSLSR_EL1 as undefined
Writes to OSLSR_EL1 are UNDEFINED and should never trap from EL1 to
EL2, but the kvm trap handler for OSLSR_EL1 handles writes via
ignore_write(). This is confusing to readers of code, but should have
no functional impact.
For clarity, use write_to_read_only() rather than ignore_write(). If a
trap is unexpectedly taken to EL2 in violation of the architecture, this
will WARN_ONCE() and inject an undef into the guest.
Reviewed-by: Reiji Watanabe <reijiw@google.com>
Reviewed-by: Mark Rutland <mark.rutland@arm.com>
[adopted Mark's changelog suggestion, thanks!]
Signed-off-by: Oliver Upton <oupton@google.com>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20220203174159.2887882-2-oupton@google.com
Diffstat (limited to 'net/batman-adv')
0 files changed, 0 insertions, 0 deletions