Message ID | 20230606175246.190465-6-miquel.raynal@bootlin.com |
---|---|
State | Superseded |
Headers | show |
Series | [v2,01/17] dt-bindings: mtd: Accept nand related node names | expand |
On 06/06/2023 19:52, Miquel Raynal wrote: > qcom,boot-partitions is a NAND chip property, not a NAND controller > property. Move the description of the property into the NAND chip > section and just enable the property in the if/else block. > > Fixes: 5278cc93a97f ("dt-bindings: mtd: qcom_nandc: document qcom,boot-partitions binding") > Cc: Manivannan Sadhasivam <mani@kernel.org> > Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> > --- > .../devicetree/bindings/mtd/qcom,nandc.yaml | 41 +++++++++++-------- > 1 file changed, 25 insertions(+), 16 deletions(-) > > diff --git a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml > index 07024ee45951..7217d8a64d14 100644 > --- a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml > +++ b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml > @@ -45,6 +45,22 @@ patternProperties: > enum: > - 512 > > + qcom,boot-partitions: > + $ref: /schemas/types.yaml#/definitions/uint32-matrix > + items: > + items: > + - description: offset > + - description: size > + description: > + Boot partition use a different layout where the 4 bytes of spare > + data are not protected by ECC. Use this to declare these special > + partitions by defining first the offset and then the size. > + > + It's in the form of <offset1 size1 offset2 size2 offset3 ...> > + and should be declared in ascending order. > + > + Refer to the ipq8064 example on how to use this special binding. > + > allOf: > - $ref: "nand-controller.yaml#" Also based on some old tree. Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Best regards, Krzysztof
Hi Krzysztof, krzysztof.kozlowski@linaro.org wrote on Mon, 19 Jun 2023 08:54:13 +0200: > On 06/06/2023 19:52, Miquel Raynal wrote: > > qcom,boot-partitions is a NAND chip property, not a NAND controller > > property. Move the description of the property into the NAND chip > > section and just enable the property in the if/else block. > > > > Fixes: 5278cc93a97f ("dt-bindings: mtd: qcom_nandc: document qcom,boot-partitions binding") > > Cc: Manivannan Sadhasivam <mani@kernel.org> > > Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> > > --- > > .../devicetree/bindings/mtd/qcom,nandc.yaml | 41 +++++++++++-------- > > 1 file changed, 25 insertions(+), 16 deletions(-) > > > > diff --git a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml > > index 07024ee45951..7217d8a64d14 100644 > > --- a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml > > +++ b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml > > @@ -45,6 +45,22 @@ patternProperties: > > enum: > > - 512 > > > > + qcom,boot-partitions: > > + $ref: /schemas/types.yaml#/definitions/uint32-matrix > > + items: > > + items: > > + - description: offset > > + - description: size > > + description: > > + Boot partition use a different layout where the 4 bytes of spare > > + data are not protected by ECC. Use this to declare these special > > + partitions by defining first the offset and then the size. > > + > > + It's in the form of <offset1 size1 offset2 size2 offset3 ...> > > + and should be declared in ascending order. > > + > > + Refer to the ipq8064 example on how to use this special binding. > > + > > allOf: > > - $ref: "nand-controller.yaml#" > > Also based on some old tree. I do have 1f79a611e74c ("dt-bindings: mtd: Drop unneeded quotes") in my log, so I don't understand the quotes. When I re-generate the patches, they no longer appear. I must have done something silly at some point without noticing. My apologies. I'll "try" again. > Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> > > Best regards, > Krzysztof > Thanks, Miquèl
diff --git a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml index 07024ee45951..7217d8a64d14 100644 --- a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml +++ b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml @@ -45,6 +45,22 @@ patternProperties: enum: - 512 + qcom,boot-partitions: + $ref: /schemas/types.yaml#/definitions/uint32-matrix + items: + items: + - description: offset + - description: size + description: + Boot partition use a different layout where the 4 bytes of spare + data are not protected by ECC. Use this to declare these special + partitions by defining first the offset and then the size. + + It's in the form of <offset1 size1 offset2 size2 offset3 ...> + and should be declared in ascending order. + + Refer to the ipq8064 example on how to use this special binding. + allOf: - $ref: "nand-controller.yaml#" @@ -107,22 +123,15 @@ allOf: - qcom,ipq806x-nand then: - properties: - qcom,boot-partitions: - $ref: /schemas/types.yaml#/definitions/uint32-matrix - items: - items: - - description: offset - - description: size - description: - Boot partition use a different layout where the 4 bytes of spare - data are not protected by ECC. Use this to declare these special - partitions by defining first the offset and then the size. - - It's in the form of <offset1 size1 offset2 size2 offset3 ...> - and should be declared in ascending order. - - Refer to the ipq8064 example on how to use this special binding. + patternProperties: + "^nand@[a-f0-9]$": + properties: + qcom,boot-partitions: true + else: + patternProperties: + "^nand@[a-f0-9]$": + properties: + qcom,boot-partitions: false required: - compatible
qcom,boot-partitions is a NAND chip property, not a NAND controller property. Move the description of the property into the NAND chip section and just enable the property in the if/else block. Fixes: 5278cc93a97f ("dt-bindings: mtd: qcom_nandc: document qcom,boot-partitions binding") Cc: Manivannan Sadhasivam <mani@kernel.org> Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> --- .../devicetree/bindings/mtd/qcom,nandc.yaml | 41 +++++++++++-------- 1 file changed, 25 insertions(+), 16 deletions(-)