From 215897da562abe5ed5a3fc71db7bbaeca32e0ddf Mon Sep 17 00:00:00 2001 From: Jörn Engel Date: Wed, 9 Mar 2005 16:40:58 -0800 Subject: [PATCH] checkstack false positive fix MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Randy Dunlap found one case where checkstack reported a false positive. From objdump of efi_stub.o: 5: 81 ea 00 00 00 c0 sub $0xc0000000,%edx With the old code, this was interpreted as a negative number. The output line was: 0xc0116f5d efi_call_phys: 1073741824 Randy wanted a change to return the correct number, like this: 0xc0116f5d efi_call_phys: 3221225472 adding "or I can just ignore it, like I've been doing for awhile..." Let's help him with the most sophisticated electronic tools and have the script actively ignore this case for him. Signed-off-by: Jörn Engel Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- scripts/checkstack.pl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'scripts/checkstack.pl') diff --git a/scripts/checkstack.pl b/scripts/checkstack.pl index 6da1d828c2c1..13ab0bef7e03 100644 --- a/scripts/checkstack.pl +++ b/scripts/checkstack.pl @@ -97,11 +97,12 @@ while (my $line = ) { my $size = $1; $size = hex($size) if ($size =~ /^0x/); - if ($size > 0x80000000) { + if ($size > 0xf0000000) { $size = - $size; $size += 0x80000000; $size += 0x80000000; } + next if ($size > 0x10000000); next if $line !~ m/^($xs*)/; my $addr = $1; -- cgit v1.2.3