devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/2] dt-bindings: DTB based validation
@ 2022-03-10 16:05 Rob Herring
  2022-03-10 16:05 ` [PATCH v2 1/2] dt-bindings: kbuild: Pass DT_SCHEMA_FILES to dt-validate Rob Herring
  2022-03-10 16:05 ` [PATCH v2 2/2] dt-bindings: kbuild: Use DTB files for validation Rob Herring
  0 siblings, 2 replies; 4+ messages in thread
From: Rob Herring @ 2022-03-10 16:05 UTC (permalink / raw)
  To: Masahiro Yamada, Krzysztof Kozlowski
  Cc: devicetree, linux-kernel, Geert Uytterhoeven, Laurent Pinchart,
	Maxime Ripard

This series switches the kernel's DT schema validation from YAML encoded
DT files to using DTB files directly. See patch 2 for the full reasoning
of why. The diffstat also shows this is a nice simplification (at least
from the kernel side). Patch 1 is further reworking of how
DT_SCHEMA_FILES works and builds on [1].

Overall, the build time is about the same (still slow) though we do save
a dtc call for dtbs_check. Extracting the type information is not cached
in any way, so there's some opportunity for a slight optimization there.

Switching to DTB validation found various issues in the bindings and
examples. Patches for those issues have already been posted and applied
over the last month or so.

v2:
 - Drop processed-schema.json dependency when building 'dtbs' 
 - Don't allow override of DT_TMP_SCHEMA

Rob

[1] https://lore.kernel.org/all/20220228201006.1484903-1-robh@kernel.org/


Rob Herring (2):
  dt-bindings: kbuild: Pass DT_SCHEMA_FILES to dt-validate
  dt-bindings: kbuild: Use DTB files for validation

 Documentation/devicetree/bindings/Makefile    | 35 ++++---------------
 .../devicetree/bindings/writing-schema.rst    | 12 -------
 scripts/Makefile.lib                          | 25 +++++--------
 scripts/dtc/Makefile                          | 13 -------
 scripts/dtc/update-dtc-source.sh              |  2 +-
 5 files changed, 16 insertions(+), 71 deletions(-)

-- 
2.32.0


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-03-11 15:30 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-03-10 16:05 [PATCH v2 0/2] dt-bindings: DTB based validation Rob Herring
2022-03-10 16:05 ` [PATCH v2 1/2] dt-bindings: kbuild: Pass DT_SCHEMA_FILES to dt-validate Rob Herring
2022-03-11 15:30   ` Rob Herring
2022-03-10 16:05 ` [PATCH v2 2/2] dt-bindings: kbuild: Use DTB files for validation Rob Herring

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).