Re: [PATCH] i386: Do backtrace fallback too

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

 



On Sat, Jul 29, 2006 at 03:54:14AM -0400, Dave Jones wrote:
> On Sat, Jul 29, 2006 at 03:00:06AM +0000, Linux Kernel wrote:
>  > commit c97d20a6c51067a38f53680d9609b4cf2867d077

[...]

> Hmm, this breaks the build for me..
> 
> arch/i386/kernel/traps.c: In function 'show_trace_log_lvl':
> arch/i386/kernel/traps.c:195: error: invalid type argument of '->'
> arch/i386/kernel/traps.c:198: error: invalid type argument of '->'
> arch/i386/kernel/traps.c:199: error: invalid type argument of '->'
> make[1]: *** [arch/i386/kernel/traps.o] Error 1
> 
> (The line numbers are different to mainline due to some unrelated
> patches, they point to the UNW_PC/UNW_SP usages),
> 
> 
> Also, shouldn't this..
> 
> 	print_symbol("DWARF2 unwinder stuck at %s\n",
> 		UNW_PC(info.regs));
> 
> be using %p ?

It should be UNWP_PC(&info), just like in the functions above. Here's a
patch:

Signed-off-by: Erik Mouw <[email protected]>

diff --git a/arch/i386/kernel/traps.c b/arch/i386/kernel/traps.c
index 3facc8f..017c015 100644
--- a/arch/i386/kernel/traps.c
+++ b/arch/i386/kernel/traps.c
@@ -190,11 +190,11 @@ static void show_trace_log_lvl(struct ta
 		if (unw_ret > 0 && !arch_unw_user_mode(&info)) {
 #ifdef CONFIG_STACK_UNWIND
 			print_symbol("DWARF2 unwinder stuck at %s\n",
-				     UNW_PC(info.regs));
+				     UNW_PC(&info));
 			if (call_trace == 1) {
 				printk("Leftover inexact backtrace:\n");
-				if (UNW_SP(info.regs))
-					stack = (void *)UNW_SP(info.regs);
+				if (UNW_SP(&info))
+					stack = (void *)UNW_SP(&info);
 			} else if (call_trace > 1)
 				return;
 			else


Erik

-- 
+-- Erik Mouw -- www.harddisk-recovery.com -- +31 70 370 12 90 --
| Lab address: Delftechpark 26, 2628 XH, Delft, The Netherlands
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux