2020-11-13 11:20:49

by Alice Guo

[permalink] [raw]
Subject: [PATCH v3 1/4] dt-bindings: soc: imx8m: add DT Binding doc for soc unique ID

Add DT Binding doc for the Unique ID of i.MX 8M series.

Signed-off-by: Alice Guo <[email protected]>
---
.../devicetree/bindings/arm/fsl.yaml | 25 +++++++++++++++++++
1 file changed, 25 insertions(+)

diff --git a/Documentation/devicetree/bindings/arm/fsl.yaml b/Documentation/devicetree/bindings/arm/fsl.yaml
index e4db0f9ed664..f4faebbb57da 100644
--- a/Documentation/devicetree/bindings/arm/fsl.yaml
+++ b/Documentation/devicetree/bindings/arm/fsl.yaml
@@ -901,6 +901,31 @@ properties:
- fsl,s32v234-evb # S32V234-EVB2 Customer Evaluation Board
- const: fsl,s32v234

+ soc:
+ type: object
+ properties:
+ compatible:
+ oneOf:
+ - description: i.MX8M SoCs
+ items:
+ - enum:
+ - fsl,imx8mm-soc
+ - fsl,imx8mn-soc
+ - fsl,imx8mp-soc
+ - fsl,imx8mq-soc
+ - const: simple-bus
+
+ - description: Other SoCs
+ items:
+ - const: simple-bus
+
+ nvmem-cells:
+ maxItems: 1
+ description: Phandle to the SOC Unique ID provided by a nvmem node
+
+ nvmem-cells-names:
+ const: soc_unique_id
+
additionalProperties: true

...
--
2.17.1


2020-11-14 15:59:57

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH v3 1/4] dt-bindings: soc: imx8m: add DT Binding doc for soc unique ID

On Fri, Nov 13, 2020 at 07:04:06PM +0800, Alice Guo wrote:
> Add DT Binding doc for the Unique ID of i.MX 8M series.
>

Please align the subject prefix with history (git log --oneline).

What are the changes comparing to v2 and v1? Where is the changelog?

Best regards,
Krzysztof

2020-11-14 16:52:45

by Krzysztof Kozlowski

[permalink] [raw]
Subject: Re: [PATCH v3 1/4] dt-bindings: soc: imx8m: add DT Binding doc for soc unique ID

On Fri, Nov 13, 2020 at 07:04:06PM +0800, Alice Guo wrote:
> Add DT Binding doc for the Unique ID of i.MX 8M series.
>
> Signed-off-by: Alice Guo <[email protected]>
> ---
> .../devicetree/bindings/arm/fsl.yaml | 25 +++++++++++++++++++
> 1 file changed, 25 insertions(+)
>
> diff --git a/Documentation/devicetree/bindings/arm/fsl.yaml b/Documentation/devicetree/bindings/arm/fsl.yaml
> index e4db0f9ed664..f4faebbb57da 100644
> --- a/Documentation/devicetree/bindings/arm/fsl.yaml
> +++ b/Documentation/devicetree/bindings/arm/fsl.yaml
> @@ -901,6 +901,31 @@ properties:
> - fsl,s32v234-evb # S32V234-EVB2 Customer Evaluation Board
> - const: fsl,s32v234
>
> + soc:
> + type: object
> + properties:
> + compatible:
> + oneOf:
> + - description: i.MX8M SoCs
> + items:
> + - enum:
> + - fsl,imx8mm-soc
> + - fsl,imx8mn-soc
> + - fsl,imx8mp-soc
> + - fsl,imx8mq-soc
> + - const: simple-bus
> +
> + - description: Other SoCs
> + items:
> + - const: simple-bus
> +
> + nvmem-cells:
> + maxItems: 1
> + description: Phandle to the SOC Unique ID provided by a nvmem node
> +
> + nvmem-cells-names:
> + const: soc_unique_id
> +
> additionalProperties: true

The "soc" node should be required for these compatibles. Otherwise you
will have to stay with this
backwards-compatible-DTB-device-initcall-glue for many years... I think
you can achieve it with allOf.

Best regards,
Krzysztof

2020-11-16 18:54:45

by Alice Guo

[permalink] [raw]
Subject: RE: [EXT] Re: [PATCH v3 1/4] dt-bindings: soc: imx8m: add DT Binding doc for soc unique ID


> -----Original Message-----
> From: Krzysztof Kozlowski <[email protected]>
> Sent: 2020年11月15日 0:50
> To: Alice Guo <[email protected]>
> Cc: [email protected]; [email protected]; [email protected];
> dl-linux-imx <[email protected]>; Peng Fan <[email protected]>;
> [email protected]; [email protected];
> [email protected]
> Subject: [EXT] Re: [PATCH v3 1/4] dt-bindings: soc: imx8m: add DT Binding doc
> for soc unique ID
>
> Caution: EXT Email
>
> On Fri, Nov 13, 2020 at 07:04:06PM +0800, Alice Guo wrote:
> > Add DT Binding doc for the Unique ID of i.MX 8M series.
> >
> > Signed-off-by: Alice Guo <[email protected]>
> > ---
> > .../devicetree/bindings/arm/fsl.yaml | 25
> +++++++++++++++++++
> > 1 file changed, 25 insertions(+)
> >
> > diff --git a/Documentation/devicetree/bindings/arm/fsl.yaml
> > b/Documentation/devicetree/bindings/arm/fsl.yaml
> > index e4db0f9ed664..f4faebbb57da 100644
> > --- a/Documentation/devicetree/bindings/arm/fsl.yaml
> > +++ b/Documentation/devicetree/bindings/arm/fsl.yaml
> > @@ -901,6 +901,31 @@ properties:
> > - fsl,s32v234-evb # S32V234-EVB2 Customer
> Evaluation Board
> > - const: fsl,s32v234
> >
> > + soc:
> > + type: object
> > + properties:
> > + compatible:
> > + oneOf:
> > + - description: i.MX8M SoCs
> > + items:
> > + - enum:
> > + - fsl,imx8mm-soc
> > + - fsl,imx8mn-soc
> > + - fsl,imx8mp-soc
> > + - fsl,imx8mq-soc
> > + - const: simple-bus
> > +
> > + - description: Other SoCs
> > + items:
> > + - const: simple-bus
> > +
> > + nvmem-cells:
> > + maxItems: 1
> > + description: Phandle to the SOC Unique ID provided by a nvmem
> > + node
> > +
> > + nvmem-cells-names:
> > + const: soc_unique_id
> > +
> > additionalProperties: true
>
> The "soc" node should be required for these compatibles. Otherwise you will
> have to stay with this backwards-compatible-DTB-device-initcall-glue for many
> years... I think you can achieve it with allOf.
>
[Alice Guo]Hi,
I find that my description for compatible is ambiguous. There are two kinds of compatible of the "soc" node:
1. For dtsi files used for SoCs other than imx8m series SoCs and old version dtsi files used for imx8m series SoCs,
compatible of the "soc" node is "simple-bus".
2. For new version dtsi files used for imx8m series SoCs, compatible of the "soc" node is {"fsl,imx8mX-soc","simple-bus"}.

"nvmem-cell" is an optional property.

I do not understand what you mean. You mean that limit the compatible of "soc" node must include " fsl,imx8mX-soc" in new version dts files. Is my understanding correct?

Best regards,
Alice

> Best regards,
> Krzysztof