summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Zijlstra <peterz@infradead.org>2021-06-21 14:12:36 +0300
committerSasha Levin <sashal@kernel.org>2021-06-30 15:47:18 +0300
commit59aa5c91f86336b9bfdb10c1ab23fb08bb291e53 (patch)
tree76d594d59b715c9eb705b561bd52b4522b4049e9
parentcb83c99cf675f3d48a343f8a17d0b953996660cb (diff)
downloadlinux-59aa5c91f86336b9bfdb10c1ab23fb08bb291e53.tar.xz
x86/xen: Fix noinstr fail in exc_xen_unknown_trap()
[ Upstream commit 4c9c26f1e67648f41f28f8c997c5c9467a3dbbe4 ] Fix: vmlinux.o: warning: objtool: exc_xen_unknown_trap()+0x7: call to printk() leaves .noinstr.text section Fixes: 2e92493637a0 ("x86/xen: avoid warning in Xen pv guest with CONFIG_AMD_MEM_ENCRYPT enabled") Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Signed-off-by: Ingo Molnar <mingo@kernel.org> Link: https://lore.kernel.org/r/20210621120120.606560778@infradead.org Signed-off-by: Sasha Levin <sashal@kernel.org>
-rw-r--r--arch/x86/xen/enlighten_pv.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/x86/xen/enlighten_pv.c b/arch/x86/xen/enlighten_pv.c
index 8064df638222..d3cdf467d91f 100644
--- a/arch/x86/xen/enlighten_pv.c
+++ b/arch/x86/xen/enlighten_pv.c
@@ -586,8 +586,10 @@ DEFINE_IDTENTRY_RAW(xenpv_exc_debug)
DEFINE_IDTENTRY_RAW(exc_xen_unknown_trap)
{
/* This should never happen and there is no way to handle it. */
+ instrumentation_begin();
pr_err("Unknown trap in Xen PV mode.");
BUG();
+ instrumentation_end();
}
struct trap_array_entry {