All of lore.kernel.org
 help / color / mirror / Atom feed
From: Albert ARIBAUD <albert.u.boot@aribaud.net>
To: u-boot@lists.denx.de
Subject: [U-Boot] [RFC PATCH 6/7] arm: Show relocated PC/LR in the register dump
Date: Tue, 3 Feb 2015 20:20:31 +0100	[thread overview]
Message-ID: <20150203202031.7202445b@lilith> (raw)
In-Reply-To: <1422644697-3735-7-git-send-email-sjg@chromium.org>

Hello Simon,

On Fri, 30 Jan 2015 12:04:56 -0700, Simon Glass <sjg@chromium.org> wrote:
> If we don't know the relocation address, the raw values are not very useful.
> Show the pre-relocation values as well as these can be looked up in
> System.map, etc.
> 
> Signed-off-by: Simon Glass <sjg@chromium.org>
> ---
> 
>  arch/arm/lib/interrupts.c | 13 +++++++++----
>  1 file changed, 9 insertions(+), 4 deletions(-)
> 
> diff --git a/arch/arm/lib/interrupts.c b/arch/arm/lib/interrupts.c
> index 4dacfd9..06f4679 100644
> --- a/arch/arm/lib/interrupts.c
> +++ b/arch/arm/lib/interrupts.c
> @@ -137,10 +137,15 @@ void show_regs (struct pt_regs *regs)
>  
>  	flags = condition_codes (regs);
>  
> -	printf ("pc : [<%08lx>]	   lr : [<%08lx>]\n"
> -		"sp : %08lx  ip : %08lx	 fp : %08lx\n",
> -		instruction_pointer (regs),
> -		regs->ARM_lr, regs->ARM_sp, regs->ARM_ip, regs->ARM_fp);
> +	printf("pc : [<%08lx>]	   lr : [<%08lx>]\n",
> +	       instruction_pointer(regs), regs->ARM_lr);
> +	if (gd->flags & GD_FLG_RELOC) {
> +		printf("reloc pc : [<%08lx>]	   lr : [<%08lx>]\n",
> +		       instruction_pointer(regs) - gd->reloc_off,
> +		       regs->ARM_lr - gd->reloc_off);
> +	}
> +	printf("sp : %08lx  ip : %08lx	 fp : %08lx\n",
> +	       regs->ARM_sp, regs->ARM_ip, regs->ARM_fp);
>  	printf ("r10: %08lx  r9 : %08lx	 r8 : %08lx\n",
>  		regs->ARM_r10, regs->ARM_r9, regs->ARM_r8);
>  	printf ("r7 : %08lx  r6 : %08lx	 r5 : %08lx  r4 : %08lx\n",
> -- 
> 2.2.0.rc0.207.ga3a616c
> 

Applied as a "bugfix" to u-boot-arm/master, thanks!

Amicalement,
-- 
Albert.

  parent reply	other threads:[~2015-02-03 19:20 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-30 19:04 [U-Boot] [RFC PATCH 0/7] RFC: dm: Add USB support Simon Glass
2015-01-30 19:04 ` [U-Boot] [RFC PATCH 1/7] dm: usb: Add a uclass for USB controllers Simon Glass
2015-02-09 20:59   ` Marek Vasut
2015-03-09  6:20   ` Vivek Gautam
2015-03-09  6:32     ` Vivek Gautam
2015-01-30 19:04 ` [U-Boot] [RFC PATCH 2/7] dm: usb: Support driver model in exynos XHCI Simon Glass
2015-01-30 19:04 ` [U-Boot] [RFC PATCH 3/7] dm: usb: Adjust users of the USB stack to work with driver model Simon Glass
2015-02-25 14:09   ` Vivek Gautam
2015-01-30 19:04 ` [U-Boot] [RFC PATCH 4/7] dm: usb: WIP sandbox USB implementation Simon Glass
2015-01-30 19:04 ` [U-Boot] [RFC PATCH 5/7] dm: core: Add a function to get the uclass data for a device Simon Glass
2015-01-30 19:04 ` [U-Boot] [RFC PATCH 6/7] arm: Show relocated PC/LR in the register dump Simon Glass
2015-02-01  8:45   ` Albert ARIBAUD
2015-02-02 16:42     ` Simon Glass
2015-02-03 19:20   ` Albert ARIBAUD [this message]
2015-01-30 19:04 ` [U-Boot] [RFC PATCH 7/7] dm: exynos: Enable driver model for snow XHCI Simon Glass
2015-01-30 22:16 ` [U-Boot] [RFC PATCH 0/7] RFC: dm: Add USB support Marek Vasut
2015-01-30 22:41   ` Simon Glass
2015-02-09 21:02     ` Marek Vasut
2015-02-10  5:28       ` Simon Glass
2015-02-10 18:52         ` Marek Vasut
2015-02-25 14:07 ` Vivek Gautam

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20150203202031.7202445b@lilith \
    --to=albert.u.boot@aribaud.net \
    --cc=u-boot@lists.denx.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.