]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
KVM: arm64: Inject UNDEF for a register trap without accessor
authorAlexandru Elisei <alexandru.elisei@arm.com>
Tue, 16 Dec 2025 10:30:51 +0000 (10:30 +0000)
committerOliver Upton <oupton@kernel.org>
Thu, 8 Jan 2026 20:56:17 +0000 (12:56 -0800)
commitaba963cb98c6d9d42490262a39c3d383cfebc6a9
tree10c7efd18ec725833de6fea98d9b822a59e49aed
parent145cc42fe1217c66174c44c4034cc0fe3040bbb0
KVM: arm64: Inject UNDEF for a register trap without accessor

Configuring a register trap without specifying an accessor function is
abviously a bug. Instead of calling die() when that happens, let's be a
bit more helpful and print the register encoding. Also inject an
undefined instruction exception in the guest, similar to other unhandled
register accesses.

Signed-off-by: Alexandru Elisei <alexandru.elisei@arm.com>
Reviewed-by: Marc Zyngier <maz@kernel.org>
Tested-by: Fuad Tabba <tabba@google.com>
Reviewed-by: Fuad Tabba <tabba@google.com>
Link: https://msgid.link/20251216103053.47224-3-alexandru.elisei@arm.com
Signed-off-by: Oliver Upton <oupton@kernel.org>
arch/arm64/kvm/sys_regs.c