[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[xen staging-4.14] x86/traps: Fix typo in do_entry_CP()

commit 9d3bac49a54ffacd44d7fffda307b211d78b2ce0
Author:     Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
AuthorDate: Fri Nov 19 09:40:19 2021 +0100
Commit:     Jan Beulich <jbeulich@xxxxxxxx>
CommitDate: Fri Nov 19 09:40:19 2021 +0100

    x86/traps: Fix typo in do_entry_CP()
    The call to debugger_trap_entry() should pass the correct vector.  The
    break-for-gdbsx logic is in practice unreachable because PV guests can't
    generate #CP, but it will interfere with anyone inserting custom debugging
    into debugger_trap_entry().
    Fixes: 5ad05b9c2490 ("x86/traps: Implement #CP handler and extend #PF for 
shadow stacks")
    Signed-off-by: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
    Reviewed-by: Jan Beulich <jbeulich@xxxxxxxx>
    master commit: 512863ed238d7390f74d43f0ba298b1dfa8f4803
    master date: 2021-11-03 19:13:17 +0000
 xen/arch/x86/traps.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/xen/arch/x86/traps.c b/xen/arch/x86/traps.c
index a38f10ad28..d8dd583a4a 100644
--- a/xen/arch/x86/traps.c
+++ b/xen/arch/x86/traps.c
@@ -1975,7 +1975,7 @@ void do_entry_CP(struct cpu_user_regs *regs)
     const char *err = "??";
     unsigned int ec = regs->error_code;
-    if ( debugger_trap_entry(TRAP_debug, regs) )
+    if ( debugger_trap_entry(X86_EXC_CP, regs) )
     /* Decode ec if possible */
generated by git-patchbot for /home/xen/git/xen.git#staging-4.14



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.