[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <333efdaa5ccfce1a0d540c266897947d7853b94f.1632402570.git.mchehab+huawei@kernel.org>
Date: Thu, 23 Sep 2021 15:30:09 +0200
From: Mauro Carvalho Chehab <mchehab+huawei@...nel.org>
To: Linux Doc Mailing List <linux-doc@...r.kernel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Cc: Mauro Carvalho Chehab <mchehab+huawei@...nel.org>,
"Jonathan Corbet" <corbet@....net>, linux-kernel@...r.kernel.org
Subject: [PATCH 11/13] scripts: get_abi.pl: stop check loop earlier when regex is found
Right now, there are two loops used to seek for a regex. Make
sure that both will be skip when a match is found.
While here, drop the unused $defined variable.
Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@...nel.org>
---
scripts/get_abi.pl | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
diff --git a/scripts/get_abi.pl b/scripts/get_abi.pl
index 42eb16eb78e9..d45e5ba56f9c 100755
--- a/scripts/get_abi.pl
+++ b/scripts/get_abi.pl
@@ -685,7 +685,6 @@ sub check_undefined_symbols {
my @names = @{$$file_ref{"__name"}};
my $file = $names[0];
- my $defined = 0;
my $exact = 0;
my $found_string;
@@ -711,13 +710,11 @@ sub check_undefined_symbols {
last;
}
}
+ last if ($exact);
}
-
- $defined++;
-
next if ($exact);
- if ($hint && $defined && (!$search_string || $found_string)) {
+ if ($hint && (!$search_string || $found_string)) {
$what =~ s/\xac/\n\t/g;
if ($leave ne "others") {
print " more likely regexes:\n\t$what\n";
--
2.31.1
Powered by blists - more mailing lists