[PATCH v2] dt-bindings: memory-controller: st,stm32: Split off MC properties
Marek Vasut
marex at denx.de
Wed Sep 28 10:44:58 PDT 2022
On 9/28/22 19:24, Krzysztof Kozlowski wrote:
> On 28/09/2022 19:01, Marek Vasut wrote:
>> On 9/28/22 09:10, Krzysztof Kozlowski wrote:
>>
>> Hi,
>>
>> [...]
>>
>>>> diff --git a/Documentation/devicetree/bindings/memory-controllers/st,stm32-fmc2-ebi.yaml b/Documentation/devicetree/bindings/memory-controllers/st,stm32-fmc2-ebi.yaml
>>>> index a1f535cececcc..49243f447eb90 100644
>>>> --- a/Documentation/devicetree/bindings/memory-controllers/st,stm32-fmc2-ebi.yaml
>>>> +++ b/Documentation/devicetree/bindings/memory-controllers/st,stm32-fmc2-ebi.yaml
>>>> @@ -49,143 +49,6 @@ patternProperties:
>>>> "^.*@[0-4],[a-f0-9]+$":
>>>> type: object
>>>>
>>>> - properties:
>>>> - reg:
>>>> - description: Bank number, base address and size of the device.
>>>> -
>>>
>>> To be equivalent (and similar to SPI peripherals and controllers) this
>>> should reference st,stm32-fmc2-ebi-props.yaml as well.
>>>
>>> After such reference, you can add here unevaluatedProperties:false
>>> (could be same or new patch as it is not related to actual split).
>>
>> I don't think I understand. I don't see any ref from the controller node
>> to its props in various SPI controllers (even if that would make sense):
>
> Because they reference spi peripheral props...
>
>>
>> next$ git grep qspi-nor-peripheral-props.yaml
>> Documentation/devicetree/bindings/spi/cdns,qspi-nor-peripheral-props.yaml:$id:
>> http://devicetree.org/schemas/spi/cdns,qspi-nor-peripheral-props.yaml#
>> Documentation/devicetree/bindings/spi/spi-peripheral-props.yaml: -
>> $ref: cdns,qspi-nor-peripheral-props.yaml#
>>
>> No ref to cdns,qspi-nor-peripheral-props.yaml in
>> Documentation/devicetree/bindings/spi/cdns,qspi-nor.yaml
>>
>> next$ git grep tegra210-quad-peripheral-props
>> Documentation/devicetree/bindings/spi/nvidia,tegra210-quad-peripheral-props.yaml:$id:
>> http://devicetree.org/schemas/spi/nvidia,tegra210-quad-peripheral-props.yaml#
>> Documentation/devicetree/bindings/spi/spi-peripheral-props.yaml: -
>> $ref: nvidia,tegra210-quad-peripheral-props.yaml#
>>
>> No ref to nvidia,tegra210-quad-peripheral-props.yaml in
>> Documentation/devicetree/bindings/spi/nvidia,tegra210-quad.yaml
>
> All your examples do it - reference spi peripheral props.
>
> As I said, your change is now not equivalent. If any other device
> appears in st,stm32-fmc2-ebi, the schema won't be applied.
>
> Let me put it that way: you must have there additionalProperties:false
> or unevaluatedProperties:false. Once you add it, you start seeing errors
> leading to missing ref.
Is what you are trying to convey that
Documentation/devicetree/bindings/spi/cdns,qspi-nor.yaml does ref
spi-controller.yaml# and that one does patternProperties: ref:
spi-peripheral-props.yaml ?
So the fix for V3 should be the following ?
diff --git
a/Documentation/devicetree/bindings/memory-controllers/st,stm32-fmc2-ebi.yaml
b/Documentation/devicetree/bindings/memory-controllers/st,stm32-fmc2-ebi.yaml
index 49243f447eb90..0448bd07f4310 100644
---
a/Documentation/devicetree/bindings/memory-controllers/st,stm32-fmc2-ebi.yaml
+++
b/Documentation/devicetree/bindings/memory-controllers/st,stm32-fmc2-ebi.yaml
@@ -48,6 +48,7 @@ properties:
patternProperties:
"^.*@[0-4],[a-f0-9]+$":
type: object
+ $ref: st,stm32-fmc2-ebi-props.yaml
required:
- "#address-cells"
More information about the linux-arm-kernel
mailing list