From: Haavard Skinnemoen Date: Thu, 12 Aug 2010 06:52:52 +0000 (+0700) Subject: avr32: Print unrelocated PC on exception X-Git-Tag: v2010.09-rc1~1^2~2^2~2 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=8d1334a7877662c5b13205b399840196c7fa0aa4;p=u-boot avr32: Print unrelocated PC on exception In addition to the real PC value, also print the value of PC after subtracting the relocation offset. This value will match the address in the ELF file so it's much easier to figure out where things went wrong. Signed-off-by: Haavard Skinnemoen --- diff --git a/arch/avr32/cpu/exception.c b/arch/avr32/cpu/exception.c index dc9c3002a4..b21ef1f928 100644 --- a/arch/avr32/cpu/exception.c +++ b/arch/avr32/cpu/exception.c @@ -59,7 +59,8 @@ void do_unknown_exception(unsigned int ecr, struct pt_regs *regs) { unsigned int mode; - printf("\n *** Unhandled exception %u at PC=0x%08lx\n", ecr, regs->pc); + printf("\n *** Unhandled exception %u at PC=0x%08lx [%08lx]\n", + ecr, regs->pc, regs->pc - gd->reloc_off); switch (ecr) { case ECR_BUS_ERROR_WRITE: