Commit 7b04e509 authored by James Morse's avatar James Morse Committed by Stefan Bader

arm64: hyp-stub: Forbid kprobing of the hyp-stub

BugLink: https://bugs.launchpad.net/bugs/1818803

commit 8fac5cbd upstream.

The hyp-stub is loaded by the kernel's early startup code at EL2
during boot, before KVM takes ownership later. The hyp-stub's
text is part of the regular kernel text, meaning it can be kprobed.

A breakpoint in the hyp-stub causes the CPU to spin in el2_sync_invalid.

Add it to the __hyp_text.
Signed-off-by: default avatarJames Morse <james.morse@arm.com>
Cc: stable@vger.kernel.org
Signed-off-by: default avatarWill Deacon <will.deacon@arm.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarJuerg Haefliger <juergh@canonical.com>
Signed-off-by: default avatarKhalid Elmously <khalid.elmously@canonical.com>
parent a3892b00
...@@ -26,6 +26,8 @@ ...@@ -26,6 +26,8 @@
#include <asm/virt.h> #include <asm/virt.h>
.text .text
.pushsection .hyp.text, "ax"
.align 11 .align 11
ENTRY(__hyp_stub_vectors) ENTRY(__hyp_stub_vectors)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment