Skip to contentSkip to conversation

checkpatch: Don't warn on "orhapned" DT schema file

PATCH Superseded Andy Shevchenko 1 participant 2 messages Oct 27, 2025 Checkpatch

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 checkpatch: Don't warn on "orhapned" DT schema file

Currently checkpatch warns is the DT schema file is absent in MAINTAINERS. However the DT schema files are self-contained in this sense and have embedded information about maintainers of it. This is a requirement. Hence, avoid checkpatch warning about it.

---
 scripts/checkpatch.pl | 12 +++++++++---
 1 file changed, 9 insertions(+), 3 deletions(-)
scripts/checkpatch.pl +9 -3
index 6729f18e5654..818b49d314ce 100755
@@ -3441,11 +3441,17 @@ sub process {
 		     ($line =~ /\{\s*([\w\/\.\-]*)\s*\=\>\s*([\w\/\.\-]*)\s*\}/ &&
 		      (defined($1) || defined($2))))) {
 			$is_patch = 1;
-			$reported_maintainer_file = 1;
-			WARN("FILE_PATH_CHANGES",
-			     "added, moved or deleted file(s), does MAINTAINERS need updating?\n" . $herecurr);
+			# DT bindings are incorporate maintainer information, no need to report
+			if ($realfile !~ m@^Documentation/devicetree/bindings/@)) {
+				$reported_maintainer_file = 1;
+				WARN("FILE_PATH_CHANGES",
+				     "added, moved or deleted file(s), does MAINTAINERS need updating?\n" . $herecurr);
+			}
 		}
 
+		    ($realfile =~ m@^Documentation/devicetree/bindings/.*\.txt$@)) {
+			if ($realfile =~ m@^include/asm/@) {
+
 # Check for adding new DT bindings not in schema format
 		if (!$in_commit_log &&
 		    ($line =~ /^new file mode\s*\d+\s*$/) &&
Signature · 1 line
2.50.1
#1 lore raw
Quoted 4 lines · Andy Shevchenko

Currently checkpatch warns is the DT schema file is absent in MAINTAINERS. However the DT schema files are self-contained in this sense and have embedded information about maintainers of it. This is a requirement. Hence, avoid checkpatch warning about it.

...

scripts/checkpatch.pl sub process { · line 3453

Quoted 2 lines
scripts/checkpatch.pl +2 -0
+		    ($realfile =~ m@^Documentation/devicetree/bindings/.*\.txt$@)) {
+			if ($realfile =~ m@^include/asm/@) {

Crap. I forgot leftovers once again, v2 is coming soon...

Signature · 2 lines
With Best Regards,
Andy Shevchenko