aboutsummaryrefslogtreecommitdiff
path: root/scripts/checkpatch.pl
diff options
context:
space:
mode:
authorPeter Xu <peterx@redhat.com>2019-04-26 14:27:05 +0800
committerPaolo Bonzini <pbonzini@redhat.com>2019-06-03 14:03:01 +0200
commit8d061278d3854fee9f907e31e0f3298263e84d82 (patch)
treecf2775ea4ca6ce9975d9c29e49562e050846de01 /scripts/checkpatch.pl
parentcbe6d6365a48bce4526c664170cda6fe738484f8 (diff)
downloadqemu-8d061278d3854fee9f907e31e0f3298263e84d82.zip
qemu-8d061278d3854fee9f907e31e0f3298263e84d82.tar.gz
qemu-8d061278d3854fee9f907e31e0f3298263e84d82.tar.bz2
checkpatch: allow SPDX-License-Identifier
According to: https://spdx.org/ids-how, let's still allow QEMU to use the SPDX license identifier: // SPDX-License-Identifier: *** CC: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Peter Xu <peterx@redhat.com> Message-Id: <20190426062705.4651-1-peterx@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'scripts/checkpatch.pl')
-rwxr-xr-xscripts/checkpatch.pl3
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 88682cb..c2aaf42 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -1949,7 +1949,8 @@ sub process {
}
# no C99 // comments
- if ($line =~ m{//}) {
+ if ($line =~ m{//} &&
+ $rawline !~ m{// SPDX-License-Identifier: }) {
ERROR("do not use C99 // comments\n" . $herecurr);
}
# Remove C99 comments.