[PATCH v2] dt-bindings: mtd: Add a schema for binman
Rob Herring
robh at kernel.org
Fri Sep 22 19:05:52 PDT 2023
On Fri, 22 Sep 2023 13:34:15 -0600, Simon Glass wrote:
> Binman[1] is a tool for creating firmware images. It allows you to
> combine various binaries and place them in an output file.
>
> Binman uses a DT schema to describe an image, in enough detail that
> it can be automatically built from component parts, disassembled,
> replaced, listed, etc.
>
> Images are typically stored in flash, which is why this binding is
> targeted at mtd. Previous discussion is at [2] [3].
>
> This is only a starting point, an attempt to align on the best way to
> add this to the schema.
>
> [1] https://u-boot.readthedocs.io/en/stable/develop/package/binman.html
> [2] https://lore.kernel.org/u-boot/20230821180220.2724080-3-sjg@chromium.org/
> [3] https://www.spinics.net/lists/devicetree/msg626149.html
>
> Signed-off-by: Simon Glass <sjg at chromium.org>
> ---
>
> Changes in v2:
> - Use "binman" for compatible instead of "u-boot,binman"
> - Significantly rework the patch
> - Use make dt_binding_check DT_SCHEMA_FILES=Documentation/../partitions
>
> .../bindings/mtd/partitions/binman.yaml | 59 ++++++++++++++++++
> .../mtd/partitions/binman/atf-bl31.yaml | 43 +++++++++++++
> .../bindings/mtd/partitions/binman/entry.yaml | 62 +++++++++++++++++++
> .../mtd/partitions/binman/u-boot.yaml | 43 +++++++++++++
> .../bindings/mtd/partitions/partitions.yaml | 1 +
> MAINTAINERS | 5 ++
> 6 files changed, 213 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/mtd/partitions/binman.yaml
> create mode 100644 Documentation/devicetree/bindings/mtd/partitions/binman/atf-bl31.yaml
> create mode 100644 Documentation/devicetree/bindings/mtd/partitions/binman/entry.yaml
> create mode 100644 Documentation/devicetree/bindings/mtd/partitions/binman/u-boot.yaml
>
My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
on your patch (DT_CHECKER_FLAGS is new in v5.13):
yamllint warnings/errors:
dtschema/dtc warnings/errors:
Documentation/devicetree/bindings/mtd/partitions/binman/atf-bl31.example.dtb: /example-0/binman/partition at 0: failed to match any schema with compatible: ['binman,entry']
Documentation/devicetree/bindings/mtd/partitions/binman/entry.example.dtb: /example-0/binman/partition at 0: failed to match any schema with compatible: ['binman,entry']
Documentation/devicetree/bindings/mtd/partitions/binman/entry.example.dtb: /example-0/binman/partition at 100000: failed to match any schema with compatible: ['binman,entry']
doc reference errors (make refcheckdocs):
See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20230922193417.1697379-1-sjg@chromium.org
The base for the series is generally the latest rc1. A different dependency
should be noted in *this* patch.
If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:
pip3 install dtschema --upgrade
Please check and re-submit after running the above command yourself. Note
that DT_SCHEMA_FILES can be set to your schema file to speed up checking
your schema. However, it must be unset to test all examples with your schema.
More information about the linux-mtd
mailing list