Skip to content

Commit 88f567f

Browse files
Ram PaiSam Ravnborg
authored andcommitted
kbuild: fix perl usage in export_report.pl
Fixes some subtle perl coding bug observed by Jan Engelhardt <jengelh@computergmbh.de> This patch applies on top of Adrian's fix. Signed-off-by: Ram Pai <linuxram@us.ibm.com> Acked-by: Jan Engelhardt <jengelh@computergmbh.de> Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
1 parent cf9a6ad commit 88f567f

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

‎scripts/export_report.pl‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -103,15 +103,15 @@ sub collectcfiles {
103103
my $state=0;
104104
while ( <MODULE_MODULE> ) {
105105
chomp;
106-
if ($state eq 0) {
106+
if ($state == 0) {
107107
$state = 1 if ($_ =~ /static const struct modversion_info/);
108108
next;
109109
}
110-
if ($state eq 1) {
110+
if ($state == 1) {
111111
$state = 2 if ($_ =~ /__attribute__\(\(section\("__versions"\)\)\)/);
112112
next;
113113
}
114-
if ($state eq 2) {
114+
if ($state == 2) {
115115
if ( $_ !~ /0x[0-9a-f]+,/ ) {
116116
next;
117117
}
@@ -121,7 +121,7 @@ sub collectcfiles {
121121
push(@{$MODULE{$thismod}} , $sym);
122122
}
123123
}
124-
if ($state ne 2) {
124+
if ($state != 2) {
125125
print "WARNING:$thismod is not built with CONFIG_MODVERSION enabled\n";
126126
}
127127
close(MODULE_MODULE);

0 commit comments

Comments
 (0)