[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200129123334.388530-1-lkundrak@v3.sk>
Date: Wed, 29 Jan 2020 13:33:34 +0100
From: Lubomir Rintel <lkundrak@...sk>
To: Andy Whitcroft <apw@...onical.com>
Cc: Joe Perches <joe@...ches.com>, Rob Herring <robh@...nel.org>,
devicetree@...r.kernel.org, linux-kernel@...r.kernel.org,
Lubomir Rintel <lkundrak@...sk>
Subject: [PATCH] checkpatch: check proper licensing of Devicetree bindings
According to Devicetree maintainers (see Link: below), the Devicetree
binding documents are preferrably licensed (GPL-2.0-only OR
BSD-2-Clause).
Let's check that. The actual check is a bit more relaxed, to allow more
liberal but compatible licensing (e.g. GPL-2.0-or-later OR
BSD-2-Clause).
Link: https://lore.kernel.org/lkml/20200108142132.GA4830@bogus/
Signed-off-by: Lubomir Rintel <lkundrak@...sk>
---
scripts/checkpatch.pl | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index e2976c3fe5ff8..ac93e98cddcee 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -3111,6 +3111,11 @@ sub process {
WARN("SPDX_LICENSE_TAG",
"'$spdx_license' is not supported in LICENSES/...\n" . $herecurr);
}
+ if ($realfile =~ m@...cumentation/devicetree/bindings/@ &&
+ not $spdx_license =~ /GPL-2\.0.*BSD-2-Clause/) {
+ WARN("SPDX_LICENSE_TAG",
+ "DT binding documents should be licensed (GPL-2.0-only OR BSD-2-Clause)\n" . $herecurr);
+ }
}
}
}
--
2.24.1
Powered by blists - more mailing lists