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

Re: [Minios-devel] [UNIKRAFT PATCH ] plat/common/x86/trace.c: Dump info on exceptions using critical printing



Reviewed-by: Stefan Teodorescu <stefanl.teodorescu@xxxxxxxxx>

On Sun, Dec 1, 2019 at 9:44 PM Costin Lupu <costin.lupu@xxxxxxxxx> wrote:
>
> Because dumping registers and stack trace on exceptions
> should be always printed.
>
> Signed-off-by: Costin Lupu <costin.lupu@xxxxxxxxx>
> ---
>  plat/common/x86/trace.c | 24 ++++++++++++------------
>  1 file changed, 12 insertions(+), 12 deletions(-)
>
> diff --git a/plat/common/x86/trace.c b/plat/common/x86/trace.c
> index ef2102e9..d1abd461 100644
> --- a/plat/common/x86/trace.c
> +++ b/plat/common/x86/trace.c
> @@ -40,18 +40,18 @@
>
>  void dump_regs(struct __regs *regs)
>  {
> -       uk_pr_info("RIP: %016lx CS: %04lx\n", regs->rip, regs->cs & 0xffff);
> -       uk_pr_info("RSP: %016lx SS: %04lx EFLAGS: %08lx\n",
> +       uk_pr_crit("RIP: %016lx CS: %04lx\n", regs->rip, regs->cs & 0xffff);
> +       uk_pr_crit("RSP: %016lx SS: %04lx EFLAGS: %08lx\n",
>                         regs->rsp, regs->ss, regs->eflags);
> -       uk_pr_info("RAX: %016lx RBX: %016lx RCX: %016lx\n",
> +       uk_pr_crit("RAX: %016lx RBX: %016lx RCX: %016lx\n",
>                         regs->rax, regs->rbx, regs->rcx);
> -       uk_pr_info("RDX: %016lx RSI: %016lx RDI: %016lx\n",
> +       uk_pr_crit("RDX: %016lx RSI: %016lx RDI: %016lx\n",
>                         regs->rdx, regs->rsi, regs->rdi);
> -       uk_pr_info("RBP: %016lx R08: %016lx R09: %016lx\n",
> +       uk_pr_crit("RBP: %016lx R08: %016lx R09: %016lx\n",
>                         regs->rbp, regs->r8, regs->r9);
> -       uk_pr_info("R10: %016lx R11: %016lx R12: %016lx\n",
> +       uk_pr_crit("R10: %016lx R11: %016lx R12: %016lx\n",
>                         regs->r10, regs->r11, regs->r12);
> -       uk_pr_info("R13: %016lx R14: %016lx R15: %016lx\n",
> +       uk_pr_crit("R13: %016lx R14: %016lx R15: %016lx\n",
>                         regs->r13, regs->r14, regs->r15);
>  }
>
> @@ -65,10 +65,10 @@ void dump_mem(unsigned long addr)
>
>         for (i = ((addr) - 16) & ~15; i < (((addr) + 48) & ~15); i++) {
>                 if (!(i % 16))
> -                       uk_pr_info("\n%lx:", i);
> -               uk_pr_info(" %02x", *(unsigned char *) i);
> +                       uk_pr_crit("\n%lx:", i);
> +               uk_pr_crit(" %02x", *(unsigned char *) i);
>         }
> -       uk_pr_info("\n");
> +       uk_pr_crit("\n");
>  }
>
>  void stack_walk(void)
> @@ -84,8 +84,8 @@ void stack_walk_for_frame(unsigned long frame_base)
>  {
>         unsigned long *frame = (void *) frame_base;
>
> -       uk_pr_info("base is %#lx ", frame_base);
> -       uk_pr_info("caller is %#lx\n", frame[1]);
> +       uk_pr_crit("base is %#lx ", frame_base);
> +       uk_pr_crit("caller is %#lx\n", frame[1]);
>         if (frame[0])
>                 stack_walk_for_frame(frame[0]);
>  }
> --
> 2.20.1
>
>
> _______________________________________________
> Minios-devel mailing list
> Minios-devel@xxxxxxxxxxxxxxxxxxxx
> https://lists.xenproject.org/mailman/listinfo/minios-devel

_______________________________________________
Minios-devel mailing list
Minios-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/minios-devel

 


Rackspace

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