Hui Zhu 1f8cdae439 markup_oops.pl: fix error with x86
When I try to use markup_oops.pl in x86, I always get:

cat 1 | perl markup_oops.pl ./vmlinux
objdump: --start-address: bad number: NaN
No matching code found

This is because in line:
	if ($line =~ /EIP is at ([a-zA-Z0-9\_]+)\+0x([0-9a-f]+)\/[a-f0-9]/) {
 		$function = $1;
 		$func_offset = $2;
 	}

$func_offset will get a number like "0x2"

But in follow code:

my $decodestart = Math::BigInt->from_hex("0x$target") -
Math::BigInt->from_hex("0x$func_offset");

It add other ox to ox2.  Then this value will be set to NaN.

So I made a small patch to fix it.

Signed-off-by: Hui Zhu <teawater@gmail.com>
Acked-by: Arjan van de Ven <arjan@linux.intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2010-01-16 12:15:37 -08:00
..
2009-12-12 13:08:16 +01:00
2005-04-16 15:20:36 -07:00
2009-06-27 00:17:48 +02:00
2005-04-16 15:20:36 -07:00
2007-12-17 19:28:17 -08:00
2008-10-22 21:53:49 -07:00
2006-07-03 23:30:54 +02:00
2008-07-25 22:12:41 +02:00
2009-06-09 22:37:54 +02:00
2009-09-15 17:04:38 -07:00
2008-04-25 20:18:48 +02:00
2008-04-25 20:18:48 +02:00
2009-09-18 21:22:08 +02:00
2005-04-16 15:20:36 -07:00
2009-06-09 22:37:54 +02:00