Messages in this thread | | | Date | Wed, 8 Sep 2021 17:02:09 +0530 | From | Pratyush Yadav <> | Subject | Re: [PATCH v3 1/2] spi: cadence: add dt-bindings documentation for Cadence XSPI controller |
| |
On 08/09/21 06:52AM, Parshuram Raju Thombare wrote: > >This needs to be a "subclass" of the spi-controller.yaml binding. > > > >allOf: > > - $ref: spi-controller.yaml# > > Isn't stating that validation need against spi-controller.yaml as well as > this schema sufficient ? Can you please point an example how to make > controller binding a "subclass" of spi-controller.yaml binding ?
I just showed you. You need to add the below lines:
allOf: - $ref: spi-controller.yaml#
See cdns,qspi-nor.yaml or nvidia,tegra210-quad.yaml or any of the multiple controller bindings we already have.
By "subclass" I did not mean a programming construct, I just meant it should logically be a subclass of the spi-controller.yaml binding, which can be done by the allOf.
> > >Node name should be flash@0. > > I think spi-controller.yaml uses wildcard for the name of a device node, > so anything in string@hexvalue: should work.
Sure, but mtd.yaml (which the SPI NOR binding depends on) requires it.
> > >> + compatible = "spi-nor", "micron,mt35xu512"; > > > >These compatibles are arbitrary and undocumented. You probably just need > >"jedec,spi-nor". If you need anything else, you need to justify why. > > Although just "spi-nor" also works, I agree to use "jedec, spi-nor" and drop > device name.
Does it? I see "jedec,spi-nor" compatible documented, but not just "spi-nor". And I don't see "micron,mt35xu512" compatible documented anywhere either.
Anyway, please just use "jedec,spi-nor".
-- Regards, Pratyush Yadav Texas Instruments Inc.
| |