summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
authorRob Herring (Arm) <robh@kernel.org>2025-12-01 11:50:29 -0600
committerRob Herring (Arm) <robh@kernel.org>2025-12-03 09:36:43 -0600
commit954c55c658e11c0cdc4cfa85968a0a5df975e26a (patch)
tree97885e8394a25784ab3b5d6a46b2706a0ce1de7b /Documentation
parent7838c7a9e2690609f137b6b8943454054ffae3cb (diff)
dt-bindings: kbuild: Skip validating empty examples
Extracting empty examples results in just the empty template being generated and then validated. That's pointless and not free, so filter out the schemas without any examples from the targets. There's currently a little less than 10% of the binding schema files without examples. Removing them improves the build time by ~6%. Link: https://patch.msgid.link/20251201175030.3785060-1-robh@kernel.org Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/devicetree/bindings/Makefile3
1 files changed, 2 insertions, 1 deletions
diff --git a/Documentation/devicetree/bindings/Makefile b/Documentation/devicetree/bindings/Makefile
index 8390d6c00030..8d6f85f4455d 100644
--- a/Documentation/devicetree/bindings/Makefile
+++ b/Documentation/devicetree/bindings/Makefile
@@ -32,7 +32,8 @@ find_cmd = $(find_all_cmd) | \
sed 's|^$(srctree)/||' | \
grep -F -e "$(subst :," -e ",$(DT_SCHEMA_FILES))" | \
sed 's|^|$(srctree)/|'
-CHK_DT_EXAMPLES := $(patsubst $(srctree)/%.yaml,%.example.dtb, $(shell $(find_cmd)))
+CHK_DT_EXAMPLES := $(patsubst $(srctree)/%.yaml,%.example.dtb, \
+ $(shell $(find_cmd) | xargs grep -l '^examples:'))
quiet_cmd_yamllint = LINT $(src)
cmd_yamllint = ($(find_cmd) | \