aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorIsaku Yamahata <isaku.yamahata@intel.com>2021-02-17 21:51:09 -0800
committerMichael S. Tsirkin <mst@redhat.com>2021-02-23 10:58:42 -0500
commitd2f1af0e41205269bd87e56e133a4353dc8de664 (patch)
tree9e120aed0ecaae56aebc456ec7bb062c6938da0d /scripts
parent2182e4058c5ac6a6fa24353c110131333c864648 (diff)
checkpatch: don't emit warning on newly created acpi data files
Newly created acpi data files(tests/data/acpi/) cause false positive warning. If file names are acpi expected file, don't emit warning. Fixes: e625ba2a41 ("checkpatch: fix acpi check with multiple file name") Signed-off-by: Isaku Yamahata <isaku.yamahata@intel.com> Message-Id: <6899f9ad54cab8e7deca94ff0eeab641680e2b5e.1613615732.git.isaku.yamahata@intel.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/checkpatch.pl4
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 7f194c842b..8f7053ec9b 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -1530,7 +1530,9 @@ sub process {
($line =~ /^(?:new|deleted) file mode\s*\d+\s*$/ ||
$line =~ /^rename (?:from|to) [\w\/\.\-]+\s*$/ ||
($line =~ /\{\s*([\w\/\.\-]*)\s*\=\>\s*([\w\/\.\-]*)\s*\}/ &&
- (defined($1) || defined($2))))) {
+ (defined($1) || defined($2)))) &&
+ !(($realfile ne '') &&
+ ($realfile eq $acpi_testexpected))) {
$reported_maintainer_file = 1;
WARN("added, moved or deleted file(s), does MAINTAINERS need updating?\n" . $herecurr);
}