History

Merge tag 'spdx-7.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/spdx

Pull SPDX update from Greg KH: "Here is a single SPDX-like change for 7.1-rc1. It explicitly allows the use of SPDX-FileCopyrightText which has been used already in many files. At the same time, update checkpatch to catch any "non allowed" spdx identifiers as we don't want to go overboard here. This has been in linux-next for a long time with no reported problems" * tag 'spdx-7.1-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/spdx: LICENSES: Explicitly allow SPDX-FileCopyrightText

Linus Torvalds committed 6 months ago

Commit f9569c62 parents cb4eb67 ebf1baf2 files · +13 −2Browse files

Unified · Split

2 files
  1. Documentation/process/license-rules.rst +5 −2
  2. scripts/checkpatch.pl +8 −0
Documentation/process/license-rules.rst+5−2
@@ -63,8 +63,11 @@ License identifier syntax · 62 unmodified lines
63 The SPDX license identifier in kernel files shall be added at the first63 The SPDX license identifier in kernel files shall be added at the first
64 possible line in a file which can contain a comment. For the majority64 possible line in a file which can contain a comment. For the majority
65 of files this is the first line, except for scripts which require the65 of files this is the first line, except for scripts which require the
66 '#!PATH_TO_INTERPRETER' in the first line. For those scripts the SPDX66 '#!PATH_TO_INTERPRETER' in the first line. For those scripts, the SPDX
67 identifier goes into the second line.67 license identifier goes into the second line.
68
69 The license identifier line can then be followed by one or multiple
70 SPDX-FileCopyrightText lines if desired.
68 71
69|72|
70 73
scripts/checkpatch.pl+8−0
@@ -3866,6 +3866,14 @@ sub process { · 3865 unmodified lines
3866 "Misplaced SPDX-License-Identifier tag - use line $checklicenseline instead\n" . $herecurr);3866 "Misplaced SPDX-License-Identifier tag - use line $checklicenseline instead\n" . $herecurr);
3867 }3867 }
3868 3868
3869# check for disallowed SPDX file tags
3870 if ($rawline =~ /\bSPDX-.*:/ &&
3871 $rawline !~ /\bSPDX-License-Identifier:/ &&
3872 $rawline !~ /\bSPDX-FileCopyrightText:/) {
3873 WARN("SPDX_LICENSE_TAG",
3874 "Disallowed SPDX tag\n" . $herecurr);
3875 }
3876
3869# line length limit (with some exclusions)3877# line length limit (with some exclusions)
3870#3878#
3871# There are a few types of lines that may extend beyond $max_line_length:3879# There are a few types of lines that may extend beyond $max_line_length: