summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorJoe Perches <joe@perches.com>2018-08-17 15:43:57 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2018-08-17 16:20:27 -0700
commitfde5e903fb5893415fa49d280e998be226d0898f (patch)
tree68122788e23a13868ab656ada908fe6b2a97ca92 /scripts
parentf08957d0ffe91f346c47cef95139c54aa7275cfe (diff)
downloadlinux-fde5e903fb5893415fa49d280e998be226d0898f.tar.bz2
scripts/spdxcheck.py: work with current HEAD LICENSES/ directory
Depending on how old your -next tree is, it may not have a master that has the LICENSES directory. Change the lookup to HEAD and find whatever LICENSE directory files are used in that branch. Miscellanea: - Remove the checkpatch test as it will have its own SPDX license identifier. Link: http://lkml.kernel.org/r/7eeefc862194930c773e662cb2152e178441d3b8.camel@perches.com Signed-off-by: Joe Perches <joe@perches.com> Reviewed-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/spdxcheck.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/scripts/spdxcheck.py b/scripts/spdxcheck.py
index 7deaef297f52..a6041f29b18e 100755
--- a/scripts/spdxcheck.py
+++ b/scripts/spdxcheck.py
@@ -32,7 +32,7 @@ def read_spdxdata(repo):
# The subdirectories of LICENSES in the kernel source
license_dirs = [ "preferred", "other", "exceptions" ]
- lictree = repo.heads.master.commit.tree['LICENSES']
+ lictree = repo.head.commit.tree['LICENSES']
spdx = SPDXdata()
@@ -199,8 +199,6 @@ def scan_git_tree(tree):
continue
if el.path.find("license-rules.rst") >= 0:
continue
- if el.path == 'scripts/checkpatch.pl':
- continue
if not os.path.isfile(el.path):
continue
parser.parse_lines(open(el.path), args.maxlines, el.path)