xen/arm: Don't dump stack when the VCPU is offline
PATCH 1/1 xen/arm: Don't dump stack when the VCPU is offline
When a VCPU is not yet online, the registers contain garbagge. This will result to call randomly BUG() in show_guest_stack.
Signed-off-by Julien Grall <[email protected]>
--- xen/arch/arm/traps.c | 6 ++++++ 1 file changed, 6 insertions(+)
xen/arch/arm/traps.c +6 -0
@@ -614,6 +614,12 @@ static void show_guest_stack(struct vcpu *v, struct cpu_user_regs *regs)void *mapped;unsigned long *stack, addr; +if (test_bit (_VPF_down, &v->pause_flags) ) + { +printk ("No stack trace, VCPU offline\n" ); +return ; + } +switch ( regs->cpsr &PSR_MODE_MASK ) {case PSR_MODE_USR :
Signature · 1 line
1.7.10.4
Quoted 4 lines · Julien Grall
When a VCPU is not yet online, the registers contain garbagge. This will result to call randomly
BUG()inshow_guest_stack.Signed-off-by Julien Grall <[email protected]>
Acked + applied, thanks.
Quoted 21 lines
--- xen/arch/arm/traps.c | 6 ++++++ 1 file changed, 6 insertions(+)xen/arch/arm/traps.c +6
-0@@ -614,6 +614,12 @@ static void show_guest_stack(struct vcpu *v, struct cpu_user_regs *regs)void *mapped;unsigned long *stack, addr; +if (test_bit (_VPF_down, &v->pause_flags) ) + { +printk ("No stack trace, VCPU offline\n" ); +return ; + } +switch ( regs->cpsr &PSR_MODE_MASK ) {case PSR_MODE_USR :