devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75
@ 2025-03-13 13:09 Kaushal Kumar
  2025-03-13 13:09 ` [PATCH 1/6] dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND Kaushal Kumar
                   ` (6 more replies)
  0 siblings, 7 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-13 13:09 UTC (permalink / raw)
  To: vkoul, robh, krzk+dt, conor+dt, manivannan.sadhasivam,
	miquel.raynal, richard, vigneshr, andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd,
	Kaushal Kumar

Hello,

This series adds and enables devicetree nodes for QPIC BAM
and QPIC NAND for Qualcomm SDX75 platform.

This patch series depends on the below patches:
https://lore.kernel.org/linux-spi/20250310120906.1577292-5-quic_mdalam@quicinc.com/T/

Kaushal Kumar (6):
  dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND
  dt-bindings: dma: qcom,bam: Document dma-coherent property
  ARM: dts: qcom: sdx75: Add QPIC BAM support
  ARM: dts: qcom: sdx75: Add QPIC NAND support
  ARM: dts: qcom: sdx75-idp: Enable QPIC BAM support
  ARM: dts: qcom: sdx75-idp: Enable QPIC NAND support

 .../devicetree/bindings/dma/qcom,bam-dma.yaml |  2 +
 .../devicetree/bindings/mtd/qcom,nandc.yaml   | 23 ++++++++---
 arch/arm64/boot/dts/qcom/sdx75-idp.dts        | 18 +++++++++
 arch/arm64/boot/dts/qcom/sdx75.dtsi           | 38 +++++++++++++++++++
 4 files changed, 75 insertions(+), 6 deletions(-)

--
2.17.1


^ permalink raw reply	[flat|nested] 20+ messages in thread

* [PATCH 1/6] dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND
  2025-03-13 13:09 [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Kaushal Kumar
@ 2025-03-13 13:09 ` Kaushal Kumar
  2025-03-13 14:31   ` Rob Herring (Arm)
  2025-03-13 14:48   ` Krzysztof Kozlowski
  2025-03-13 13:09 ` [PATCH 2/6] dt-bindings: dma: qcom,bam: Document dma-coherent property Kaushal Kumar
                   ` (5 subsequent siblings)
  6 siblings, 2 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-13 13:09 UTC (permalink / raw)
  To: vkoul, robh, krzk+dt, conor+dt, manivannan.sadhasivam,
	miquel.raynal, richard, vigneshr, andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd,
	Kaushal Kumar

Document the QPIC NAND controller v2.1.1 being used in
SDX75 SoC and it uses BAM DMA.

SDX75 NAND controller has DMA-coherent and iommu support
so define them in the properties section, without which
'dtbs_check' reports the following error:

  nand-controller@1cc8000: Unevaluated properties are not
  allowed ('dma-coherent', 'iommus' were unexpected)

Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
---
 .../devicetree/bindings/mtd/qcom,nandc.yaml   | 23 ++++++++++++++-----
 1 file changed, 17 insertions(+), 6 deletions(-)

diff --git a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml
index 35b4206ea918..8b77e8837205 100644
--- a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml
+++ b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml
@@ -11,12 +11,17 @@ maintainers:
 
 properties:
   compatible:
-    enum:
-      - qcom,ipq806x-nand
-      - qcom,ipq4019-nand
-      - qcom,ipq6018-nand
-      - qcom,ipq8074-nand
-      - qcom,sdx55-nand
+    OneOf:
+      - items:
+          - enum:
+              - qcom,sdx75-nand
+          - const: qcom,sdx55-nand
+      - items:
+          - const: qcom,ipq806x-nand
+          - const: qcom,ipq4019-nand
+          - const: qcom,ipq6018-nand
+          - const: qcom,ipq8074-nand
+          - const: qcom,sdx55-nand
 
   reg:
     maxItems: 1
@@ -31,6 +36,12 @@ properties:
       - const: core
       - const: aon
 
+  dma-coherent: true
+
+  iommus:
+    minItems: 1
+    maxItems: 3
+
   qcom,cmd-crci:
     $ref: /schemas/types.yaml#/definitions/uint32
     description:
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [PATCH 2/6] dt-bindings: dma: qcom,bam: Document dma-coherent property
  2025-03-13 13:09 [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Kaushal Kumar
  2025-03-13 13:09 ` [PATCH 1/6] dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND Kaushal Kumar
@ 2025-03-13 13:09 ` Kaushal Kumar
  2025-03-13 14:50   ` Krzysztof Kozlowski
  2025-03-13 13:09 ` [PATCH 3/6] ARM: dts: qcom: sdx75: Add QPIC BAM support Kaushal Kumar
                   ` (4 subsequent siblings)
  6 siblings, 1 reply; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-13 13:09 UTC (permalink / raw)
  To: vkoul, robh, krzk+dt, conor+dt, manivannan.sadhasivam,
	miquel.raynal, richard, vigneshr, andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd,
	Kaushal Kumar

SDX75 BAM DMA controller has DMA-coherent support so define
it in the properties section, without which 'dtbs_check'
reports the following error:

  controller@1c9c000: 'dma-coherent' does not match any of the
  regexes: 'pinctrl-[0-9]+'

Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
---
 Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml b/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml
index 3ad0d9b1fbc5..c4dd6a503964 100644
--- a/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml
+++ b/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml
@@ -39,6 +39,8 @@ properties:
   "#dma-cells":
     const: 1
 
+  dma-coherent: true
+
   interrupts:
     maxItems: 1
 
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [PATCH 3/6] ARM: dts: qcom: sdx75: Add QPIC BAM support
  2025-03-13 13:09 [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Kaushal Kumar
  2025-03-13 13:09 ` [PATCH 1/6] dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND Kaushal Kumar
  2025-03-13 13:09 ` [PATCH 2/6] dt-bindings: dma: qcom,bam: Document dma-coherent property Kaushal Kumar
@ 2025-03-13 13:09 ` Kaushal Kumar
  2025-03-13 13:09 ` [PATCH 4/6] ARM: dts: qcom: sdx75: Add QPIC NAND support Kaushal Kumar
                   ` (3 subsequent siblings)
  6 siblings, 0 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-13 13:09 UTC (permalink / raw)
  To: vkoul, robh, krzk+dt, conor+dt, manivannan.sadhasivam,
	miquel.raynal, richard, vigneshr, andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd,
	Kaushal Kumar

Add devicetree node to enable support for QPIC
BAM DMA controller on Qualcomm SDX75 platform.

Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
---
 arch/arm64/boot/dts/qcom/sdx75.dtsi | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/sdx75.dtsi b/arch/arm64/boot/dts/qcom/sdx75.dtsi
index b0a8a0fe5f39..e3a0ee661c4a 100644
--- a/arch/arm64/boot/dts/qcom/sdx75.dtsi
+++ b/arch/arm64/boot/dts/qcom/sdx75.dtsi
@@ -880,6 +880,20 @@
 			qcom,bcm-voters = <&apps_bcm_voter>;
 		};
 
+		qpic_bam: dma-controller@1c9c000 {
+			compatible = "qcom,bam-v1.7.0";
+			reg = <0x0 0x01c9c000 0x0 0x1c000>;
+			interrupts = <GIC_SPI 135 IRQ_TYPE_LEVEL_HIGH>;
+			clocks = <&rpmhcc RPMH_QPIC_CLK>;
+			clock-names = "bam_clk";
+			#dma-cells = <1>;
+			qcom,ee = <0>;
+			qcom,controlled-remotely;
+			iommus = <&apps_smmu 0x100 0x3>;
+			dma-coherent;
+			status = "disabled";
+		};
+
 		tcsr_mutex: hwlock@1f40000 {
 			compatible = "qcom,tcsr-mutex";
 			reg = <0x0 0x01f40000 0x0 0x40000>;
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [PATCH 4/6] ARM: dts: qcom: sdx75: Add QPIC NAND support
  2025-03-13 13:09 [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Kaushal Kumar
                   ` (2 preceding siblings ...)
  2025-03-13 13:09 ` [PATCH 3/6] ARM: dts: qcom: sdx75: Add QPIC BAM support Kaushal Kumar
@ 2025-03-13 13:09 ` Kaushal Kumar
  2025-03-13 14:36   ` Konrad Dybcio
  2025-03-13 14:50   ` Krzysztof Kozlowski
  2025-03-13 13:09 ` [PATCH 5/6] ARM: dts: qcom: sdx75-idp: Enable QPIC BAM support Kaushal Kumar
                   ` (2 subsequent siblings)
  6 siblings, 2 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-13 13:09 UTC (permalink / raw)
  To: vkoul, robh, krzk+dt, conor+dt, manivannan.sadhasivam,
	miquel.raynal, richard, vigneshr, andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd,
	Kaushal Kumar

Add devicetree node to enable support for QPIC
NAND controller on Qualcomm SDX75 platform.
Since there is no "aon" clock in SDX75, a dummy
clock is provided.

Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
---
 arch/arm64/boot/dts/qcom/sdx75.dtsi | 24 ++++++++++++++++++++++++
 1 file changed, 24 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/sdx75.dtsi b/arch/arm64/boot/dts/qcom/sdx75.dtsi
index e3a0ee661c4a..9c43b14a0594 100644
--- a/arch/arm64/boot/dts/qcom/sdx75.dtsi
+++ b/arch/arm64/boot/dts/qcom/sdx75.dtsi
@@ -37,6 +37,12 @@
 			clock-frequency = <32764>;
 			#clock-cells = <0>;
 		};
+
+		nand_clk_dummy: nand-clk-dummy {
+			compatible = "fixed-clock";
+			clock-frequency = <32764>;
+			#clock-cells = <0>;
+		};
 	};
 
 	cpus {
@@ -894,6 +900,24 @@
 			status = "disabled";
 		};
 
+		qpic_nand: nand-controller@1cc8000 {
+			compatible = "qcom,sdx75-nand", "qcom,sdx55-nand";
+			reg = <0x0 0x01cc8000 0x0 0x10000>;
+			#address-cells = <1>;
+			#size-cells = <0>;
+			clocks = <&rpmhcc RPMH_QPIC_CLK>,
+				 <&nand_clk_dummy>;
+			clock-names = "core", "aon";
+
+			dmas = <&qpic_bam 0>,
+			       <&qpic_bam 1>,
+			       <&qpic_bam 2>;
+			dma-names = "tx", "rx", "cmd";
+			iommus = <&apps_smmu 0x100 0x3>;
+			dma-coherent;
+			status = "disabled";
+		};
+
 		tcsr_mutex: hwlock@1f40000 {
 			compatible = "qcom,tcsr-mutex";
 			reg = <0x0 0x01f40000 0x0 0x40000>;
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [PATCH 5/6] ARM: dts: qcom: sdx75-idp: Enable QPIC BAM support
  2025-03-13 13:09 [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Kaushal Kumar
                   ` (3 preceding siblings ...)
  2025-03-13 13:09 ` [PATCH 4/6] ARM: dts: qcom: sdx75: Add QPIC NAND support Kaushal Kumar
@ 2025-03-13 13:09 ` Kaushal Kumar
  2025-03-13 14:37   ` Konrad Dybcio
  2025-03-13 13:09 ` [PATCH 6/6] ARM: dts: qcom: sdx75-idp: Enable QPIC NAND support Kaushal Kumar
  2025-03-13 14:30 ` [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Konrad Dybcio
  6 siblings, 1 reply; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-13 13:09 UTC (permalink / raw)
  To: vkoul, robh, krzk+dt, conor+dt, manivannan.sadhasivam,
	miquel.raynal, richard, vigneshr, andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd,
	Kaushal Kumar

Enable QPIC BAM devicetree node for Qualcomm SDX75-IDP board.

Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
---
 arch/arm64/boot/dts/qcom/sdx75-idp.dts | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/sdx75-idp.dts b/arch/arm64/boot/dts/qcom/sdx75-idp.dts
index f1bbe7ab01ab..26f7e38b8a6e 100644
--- a/arch/arm64/boot/dts/qcom/sdx75-idp.dts
+++ b/arch/arm64/boot/dts/qcom/sdx75-idp.dts
@@ -278,6 +278,10 @@
 	vdd3-supply = <&vreg_l10b_3p08>;
 };
 
+&qpic_bam {
+	status = "okay";
+};
+
 &qupv3_id_0 {
 	status = "okay";
 };
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* [PATCH 6/6] ARM: dts: qcom: sdx75-idp: Enable QPIC NAND support
  2025-03-13 13:09 [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Kaushal Kumar
                   ` (4 preceding siblings ...)
  2025-03-13 13:09 ` [PATCH 5/6] ARM: dts: qcom: sdx75-idp: Enable QPIC BAM support Kaushal Kumar
@ 2025-03-13 13:09 ` Kaushal Kumar
  2025-03-13 14:30 ` [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Konrad Dybcio
  6 siblings, 0 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-13 13:09 UTC (permalink / raw)
  To: vkoul, robh, krzk+dt, conor+dt, manivannan.sadhasivam,
	miquel.raynal, richard, vigneshr, andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd,
	Kaushal Kumar

Enable QPIC NAND devicetree node for Qualcomm SDX75-IDP board.

Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
---
 arch/arm64/boot/dts/qcom/sdx75-idp.dts | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/arch/arm64/boot/dts/qcom/sdx75-idp.dts b/arch/arm64/boot/dts/qcom/sdx75-idp.dts
index 26f7e38b8a6e..06cacec3461f 100644
--- a/arch/arm64/boot/dts/qcom/sdx75-idp.dts
+++ b/arch/arm64/boot/dts/qcom/sdx75-idp.dts
@@ -282,6 +282,20 @@
 	status = "okay";
 };
 
+&qpic_nand {
+	status = "okay";
+
+	nand@0 {
+		reg = <0>;
+
+		nand-ecc-strength = <8>;
+		nand-ecc-step-size = <512>;
+		nand-bus-width = <8>;
+		/* efs2 partition is secured */
+		secure-regions = /bits/ 64 <0x680000 0xb00000>;
+	};
+};
+
 &qupv3_id_0 {
 	status = "okay";
 };
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 20+ messages in thread

* Re: [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75
  2025-03-13 13:09 [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Kaushal Kumar
                   ` (5 preceding siblings ...)
  2025-03-13 13:09 ` [PATCH 6/6] ARM: dts: qcom: sdx75-idp: Enable QPIC NAND support Kaushal Kumar
@ 2025-03-13 14:30 ` Konrad Dybcio
  2025-03-27 10:23   ` Kaushal Kumar
  6 siblings, 1 reply; 20+ messages in thread
From: Konrad Dybcio @ 2025-03-13 14:30 UTC (permalink / raw)
  To: Kaushal Kumar, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 3/13/25 2:09 PM, Kaushal Kumar wrote:
> Hello,
> 
> This series adds and enables devicetree nodes for QPIC BAM
> and QPIC NAND for Qualcomm SDX75 platform.
> 
> This patch series depends on the below patches:
> https://lore.kernel.org/linux-spi/20250310120906.1577292-5-quic_mdalam@quicinc.com/T/
> 
> Kaushal Kumar (6):
>   dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND
>   dt-bindings: dma: qcom,bam: Document dma-coherent property
>   ARM: dts: qcom: sdx75: Add QPIC BAM support
>   ARM: dts: qcom: sdx75: Add QPIC NAND support
>   ARM: dts: qcom: sdx75-idp: Enable QPIC BAM support
>   ARM: dts: qcom: sdx75-idp: Enable QPIC NAND support

subjects: sdx75 is arm64 and the prefix in that dir is:

arm64: dts: qcom: <soc/board>: foo

Konrad

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 1/6] dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND
  2025-03-13 13:09 ` [PATCH 1/6] dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND Kaushal Kumar
@ 2025-03-13 14:31   ` Rob Herring (Arm)
  2025-03-13 14:48   ` Krzysztof Kozlowski
  1 sibling, 0 replies; 20+ messages in thread
From: Rob Herring (Arm) @ 2025-03-13 14:31 UTC (permalink / raw)
  To: Kaushal Kumar
  Cc: vigneshr, andersson, linux-mtd, miquel.raynal, conor+dt, agross,
	krzk+dt, linux-arm-msm, richard, dmaengine, vkoul, devicetree,
	linux-kernel, konradybcio, manivannan.sadhasivam


On Thu, 13 Mar 2025 18:39:13 +0530, Kaushal Kumar wrote:
> Document the QPIC NAND controller v2.1.1 being used in
> SDX75 SoC and it uses BAM DMA.
> 
> SDX75 NAND controller has DMA-coherent and iommu support
> so define them in the properties section, without which
> 'dtbs_check' reports the following error:
> 
>   nand-controller@1cc8000: Unevaluated properties are not
>   allowed ('dma-coherent', 'iommus' were unexpected)
> 
> Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
> ---
>  .../devicetree/bindings/mtd/qcom,nandc.yaml   | 23 ++++++++++++++-----
>  1 file changed, 17 insertions(+), 6 deletions(-)
> 

My bot found errors running 'make dt_binding_check' on your patch:

yamllint warnings/errors:

dtschema/dtc warnings/errors:
/builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml: properties:compatible: 'anyOf' conditional failed, one must be fixed:
	'OneOf' is not one of ['$ref', 'additionalItems', 'additionalProperties', 'allOf', 'anyOf', 'const', 'contains', 'default', 'dependencies', 'dependentRequired', 'dependentSchemas', 'deprecated', 'description', 'else', 'enum', 'exclusiveMaximum', 'exclusiveMinimum', 'items', 'if', 'minItems', 'minimum', 'maxItems', 'maximum', 'multipleOf', 'not', 'oneOf', 'pattern', 'patternProperties', 'properties', 'required', 'then', 'typeSize', 'unevaluatedProperties', 'uniqueItems']
	'type' was expected
	from schema $id: http://devicetree.org/meta-schemas/keywords.yaml#
/builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml: properties:compatible: Additional properties are not allowed ('OneOf' was unexpected)
	from schema $id: http://devicetree.org/meta-schemas/string-array.yaml#

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20250313130918.4238-2-quic_kaushalk@quicinc.com

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.


^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 4/6] ARM: dts: qcom: sdx75: Add QPIC NAND support
  2025-03-13 13:09 ` [PATCH 4/6] ARM: dts: qcom: sdx75: Add QPIC NAND support Kaushal Kumar
@ 2025-03-13 14:36   ` Konrad Dybcio
  2025-03-27 10:48     ` Kaushal Kumar
  2025-03-13 14:50   ` Krzysztof Kozlowski
  1 sibling, 1 reply; 20+ messages in thread
From: Konrad Dybcio @ 2025-03-13 14:36 UTC (permalink / raw)
  To: Kaushal Kumar, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 3/13/25 2:09 PM, Kaushal Kumar wrote:
> Add devicetree node to enable support for QPIC
> NAND controller on Qualcomm SDX75 platform.
> Since there is no "aon" clock in SDX75, a dummy
> clock is provided.

Alter the bindings not to require it then, instead

[...]

>  
> +		qpic_nand: nand-controller@1cc8000 {
> +			compatible = "qcom,sdx75-nand", "qcom,sdx55-nand";
> +			reg = <0x0 0x01cc8000 0x0 0x10000>;
> +			#address-cells = <1>;
> +			#size-cells = <0>;
> +			clocks = <&rpmhcc RPMH_QPIC_CLK>,
> +				 <&nand_clk_dummy>;
> +			clock-names = "core", "aon";
> +
> +			dmas = <&qpic_bam 0>,
> +			       <&qpic_bam 1>,
> +			       <&qpic_bam 2>;
> +			dma-names = "tx", "rx", "cmd";

Please make dma-names a vertical list, just like dmas

Konrad

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 5/6] ARM: dts: qcom: sdx75-idp: Enable QPIC BAM support
  2025-03-13 13:09 ` [PATCH 5/6] ARM: dts: qcom: sdx75-idp: Enable QPIC BAM support Kaushal Kumar
@ 2025-03-13 14:37   ` Konrad Dybcio
  2025-03-27 10:25     ` Kaushal Kumar
  0 siblings, 1 reply; 20+ messages in thread
From: Konrad Dybcio @ 2025-03-13 14:37 UTC (permalink / raw)
  To: Kaushal Kumar, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 3/13/25 2:09 PM, Kaushal Kumar wrote:
> Enable QPIC BAM devicetree node for Qualcomm SDX75-IDP board.
> 
> Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
> ---

There's not reason for this to be a separate commit

Konrad

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 1/6] dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND
  2025-03-13 13:09 ` [PATCH 1/6] dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND Kaushal Kumar
  2025-03-13 14:31   ` Rob Herring (Arm)
@ 2025-03-13 14:48   ` Krzysztof Kozlowski
  2025-03-27 10:42     ` Kaushal Kumar
  1 sibling, 1 reply; 20+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-13 14:48 UTC (permalink / raw)
  To: Kaushal Kumar, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 13/03/2025 14:09, Kaushal Kumar wrote:
> Document the QPIC NAND controller v2.1.1 being used in
> SDX75 SoC and it uses BAM DMA.

Please wrap commit message according to Linux coding style / submission
process (neither too early nor over the limit):
https://elixir.bootlin.com/linux/v6.4-rc1/source/Documentation/process/submitting-patches.rst#L597

> 
> SDX75 NAND controller has DMA-coherent and iommu support
> so define them in the properties section, without which
> 'dtbs_check' reports the following error:
> 
>   nand-controller@1cc8000: Unevaluated properties are not
>   allowed ('dma-coherent', 'iommus' were unexpected)

That's a new compatible, so how can you have existing errors? Looks not
related.

> 
> Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
> ---
>  .../devicetree/bindings/mtd/qcom,nandc.yaml   | 23 ++++++++++++++-----
>  1 file changed, 17 insertions(+), 6 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml
> index 35b4206ea918..8b77e8837205 100644
> --- a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml
> +++ b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml
> @@ -11,12 +11,17 @@ maintainers:
>  
>  properties:
>    compatible:
> -    enum:
> -      - qcom,ipq806x-nand
> -      - qcom,ipq4019-nand
> -      - qcom,ipq6018-nand
> -      - qcom,ipq8074-nand
> -      - qcom,sdx55-nand
> +    OneOf:

Testing patches before sending is still on todo list for Qualcomm :/.

> +      - items:
> +          - enum:
> +              - qcom,sdx75-nand
> +          - const: qcom,sdx55-nand
> +      - items:
> +          - const: qcom,ipq806x-nand
> +          - const: qcom,ipq4019-nand
> +          - const: qcom,ipq6018-nand
> +          - const: qcom,ipq8074-nand
> +          - const: qcom,sdx55-nand
>  
>    reg:
>      maxItems: 1
> @@ -31,6 +36,12 @@ properties:
>        - const: core
>        - const: aon
>  
> +  dma-coherent: true

Which controllers are DMA coherent?

> +
> +  iommus:
> +    minItems: 1
> +    maxItems: 3

You need to list the items. Why is this flexible?

> +
>    qcom,cmd-crci:
>      $ref: /schemas/types.yaml#/definitions/uint32
>      description:


Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 2/6] dt-bindings: dma: qcom,bam: Document dma-coherent property
  2025-03-13 13:09 ` [PATCH 2/6] dt-bindings: dma: qcom,bam: Document dma-coherent property Kaushal Kumar
@ 2025-03-13 14:50   ` Krzysztof Kozlowski
  2025-03-27 10:46     ` Kaushal Kumar
  0 siblings, 1 reply; 20+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-13 14:50 UTC (permalink / raw)
  To: Kaushal Kumar, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 13/03/2025 14:09, Kaushal Kumar wrote:
> SDX75 BAM DMA controller has DMA-coherent support so define
> it in the properties section, without which 'dtbs_check'
> reports the following error:
> 
>   controller@1c9c000: 'dma-coherent' does not match any of the
>   regexes: 'pinctrl-[0-9]+'

How can I reproduce it?

> 

Fixes tag?

> Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
> ---
>  Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml b/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml
> index 3ad0d9b1fbc5..c4dd6a503964 100644
> --- a/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml
> +++ b/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml
> @@ -39,6 +39,8 @@ properties:
>    "#dma-cells":
>      const: 1
>  
> +  dma-coherent: true
> +

Which devices are DMA coherent?


Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 4/6] ARM: dts: qcom: sdx75: Add QPIC NAND support
  2025-03-13 13:09 ` [PATCH 4/6] ARM: dts: qcom: sdx75: Add QPIC NAND support Kaushal Kumar
  2025-03-13 14:36   ` Konrad Dybcio
@ 2025-03-13 14:50   ` Krzysztof Kozlowski
  2025-03-27 10:47     ` Kaushal Kumar
  1 sibling, 1 reply; 20+ messages in thread
From: Krzysztof Kozlowski @ 2025-03-13 14:50 UTC (permalink / raw)
  To: Kaushal Kumar, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 13/03/2025 14:09, Kaushal Kumar wrote:
> Add devicetree node to enable support for QPIC
> NAND controller on Qualcomm SDX75 platform.
> Since there is no "aon" clock in SDX75, a dummy
> clock is provided.

Add the clock first.

Please wrap code according to the preferred limit expressed in Kernel
coding style (checkpatch is not a coding style description, but only a
tool).  However don't wrap blindly (see Kernel coding style).

Best regards,
Krzysztof

^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75
  2025-03-13 14:30 ` [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Konrad Dybcio
@ 2025-03-27 10:23   ` Kaushal Kumar
  0 siblings, 0 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-27 10:23 UTC (permalink / raw)
  To: Konrad Dybcio, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 3/13/2025 8:00 PM, Konrad Dybcio wrote:
> On 3/13/25 2:09 PM, Kaushal Kumar wrote:
>> Hello,
>>
>> This series adds and enables devicetree nodes for QPIC BAM
>> and QPIC NAND for Qualcomm SDX75 platform.
>>
>> This patch series depends on the below patches:
>> https://lore.kernel.org/linux-spi/20250310120906.1577292-5-quic_mdalam@quicinc.com/T/
>>
>> Kaushal Kumar (6):
>>    dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND
>>    dt-bindings: dma: qcom,bam: Document dma-coherent property
>>    ARM: dts: qcom: sdx75: Add QPIC BAM support
>>    ARM: dts: qcom: sdx75: Add QPIC NAND support
>>    ARM: dts: qcom: sdx75-idp: Enable QPIC BAM support
>>    ARM: dts: qcom: sdx75-idp: Enable QPIC NAND support
> subjects: sdx75 is arm64 and the prefix in that dir is:
>
> arm64: dts: qcom: <soc/board>: foo
Agree, will update in v2.
>
> Konrad


^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 5/6] ARM: dts: qcom: sdx75-idp: Enable QPIC BAM support
  2025-03-13 14:37   ` Konrad Dybcio
@ 2025-03-27 10:25     ` Kaushal Kumar
  0 siblings, 0 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-27 10:25 UTC (permalink / raw)
  To: Konrad Dybcio, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 3/13/2025 8:07 PM, Konrad Dybcio wrote:
> On 3/13/25 2:09 PM, Kaushal Kumar wrote:
>> Enable QPIC BAM devicetree node for Qualcomm SDX75-IDP board.
>>
>> Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
>> ---
> There's not reason for this to be a separate commit
Okay, will combine it along with nand enablement in v2.
>
> Konrad


^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 1/6] dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND
  2025-03-13 14:48   ` Krzysztof Kozlowski
@ 2025-03-27 10:42     ` Kaushal Kumar
  0 siblings, 0 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-27 10:42 UTC (permalink / raw)
  To: Krzysztof Kozlowski, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 3/13/2025 8:18 PM, Krzysztof Kozlowski wrote:
> On 13/03/2025 14:09, Kaushal Kumar wrote:
>> Document the QPIC NAND controller v2.1.1 being used in
>> SDX75 SoC and it uses BAM DMA.
> Please wrap commit message according to Linux coding style / submission
> process (neither too early nor over the limit):
> https://elixir.bootlin.com/linux/v6.4-rc1/source/Documentation/process/submitting-patches.rst#L597
Sure, will update in v2.
>> SDX75 NAND controller has DMA-coherent and iommu support
>> so define them in the properties section, without which
>> 'dtbs_check' reports the following error:
>>
>>    nand-controller@1cc8000: Unevaluated properties are not
>>    allowed ('dma-coherent', 'iommus' were unexpected)
> That's a new compatible, so how can you have existing errors? Looks not
> related.
It is not an existing error. It is the error that would come unless the 
new properties are updated. Anyhow sorry for the confusion, will remove 
this in v2.
>> Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
>> ---
>>   .../devicetree/bindings/mtd/qcom,nandc.yaml   | 23 ++++++++++++++-----
>>   1 file changed, 17 insertions(+), 6 deletions(-)
>>
>> diff --git a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml
>> index 35b4206ea918..8b77e8837205 100644
>> --- a/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml
>> +++ b/Documentation/devicetree/bindings/mtd/qcom,nandc.yaml
>> @@ -11,12 +11,17 @@ maintainers:
>>   
>>   properties:
>>     compatible:
>> -    enum:
>> -      - qcom,ipq806x-nand
>> -      - qcom,ipq4019-nand
>> -      - qcom,ipq6018-nand
>> -      - qcom,ipq8074-nand
>> -      - qcom,sdx55-nand
>> +    OneOf:
> Testing patches before sending is still on todo list for Qualcomm :/.
I had run the "make dt_binding_check". Possibly due to my older version 
of dtschema , it did not get caught. After the schema update, now it is 
getting caught. Will update in v2.
>> +      - items:
>> +          - enum:
>> +              - qcom,sdx75-nand
>> +          - const: qcom,sdx55-nand
>> +      - items:
>> +          - const: qcom,ipq806x-nand
>> +          - const: qcom,ipq4019-nand
>> +          - const: qcom,ipq6018-nand
>> +          - const: qcom,ipq8074-nand
>> +          - const: qcom,sdx55-nand
>>   
>>     reg:
>>       maxItems: 1
>> @@ -31,6 +36,12 @@ properties:
>>         - const: core
>>         - const: aon
>>   
>> +  dma-coherent: true
> Which controllers are DMA coherent?
I will add it under a sdx75 check since it is applicable to sdx75 only.
>
>> +
>> +  iommus:
>> +    minItems: 1
>> +    maxItems: 3
> You need to list the items. Why is this flexible?
Agree, this need not be flexible. Will update in v2.
>
>> +
>>     qcom,cmd-crci:
>>       $ref: /schemas/types.yaml#/definitions/uint32
>>       description:
>
> Best regards,
> Krzysztof


^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 2/6] dt-bindings: dma: qcom,bam: Document dma-coherent property
  2025-03-13 14:50   ` Krzysztof Kozlowski
@ 2025-03-27 10:46     ` Kaushal Kumar
  0 siblings, 0 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-27 10:46 UTC (permalink / raw)
  To: Krzysztof Kozlowski, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 3/13/2025 8:20 PM, Krzysztof Kozlowski wrote:
> On 13/03/2025 14:09, Kaushal Kumar wrote:
>> SDX75 BAM DMA controller has DMA-coherent support so define
>> it in the properties section, without which 'dtbs_check'
>> reports the following error:
>>
>>    controller@1c9c000: 'dma-coherent' does not match any of the
>>    regexes: 'pinctrl-[0-9]+'
> How can I reproduce it?
It is not an existing error. It is the error that would come unless the 
new property is defined. Will remove this part of commit text in v2.
> Fixes tag?
>
>> Signed-off-by: Kaushal Kumar <quic_kaushalk@quicinc.com>
>> ---
>>   Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml | 2 ++
>>   1 file changed, 2 insertions(+)
>>
>> diff --git a/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml b/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml
>> index 3ad0d9b1fbc5..c4dd6a503964 100644
>> --- a/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml
>> +++ b/Documentation/devicetree/bindings/dma/qcom,bam-dma.yaml
>> @@ -39,6 +39,8 @@ properties:
>>     "#dma-cells":
>>       const: 1
>>   
>> +  dma-coherent: true
>> +
> Which devices are DMA coherent?
Will update it under a bam version check in v2.
>
>
> Best regards,
> Krzysztof


^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 4/6] ARM: dts: qcom: sdx75: Add QPIC NAND support
  2025-03-13 14:50   ` Krzysztof Kozlowski
@ 2025-03-27 10:47     ` Kaushal Kumar
  0 siblings, 0 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-27 10:47 UTC (permalink / raw)
  To: Krzysztof Kozlowski, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd

On 3/13/2025 8:20 PM, Krzysztof Kozlowski wrote:
> On 13/03/2025 14:09, Kaushal Kumar wrote:
>> Add devicetree node to enable support for QPIC
>> NAND controller on Qualcomm SDX75 platform.
>> Since there is no "aon" clock in SDX75, a dummy
>> clock is provided.
> Add the clock first.
>
> Please wrap code according to the preferred limit expressed in Kernel
> coding style (checkpatch is not a coding style description, but only a
> tool).  However don't wrap blindly (see Kernel coding style).
Sure, will update in v2.
> Best regards,
> Krzysztof


^ permalink raw reply	[flat|nested] 20+ messages in thread

* Re: [PATCH 4/6] ARM: dts: qcom: sdx75: Add QPIC NAND support
  2025-03-13 14:36   ` Konrad Dybcio
@ 2025-03-27 10:48     ` Kaushal Kumar
  0 siblings, 0 replies; 20+ messages in thread
From: Kaushal Kumar @ 2025-03-27 10:48 UTC (permalink / raw)
  To: Konrad Dybcio, vkoul, robh, krzk+dt, conor+dt,
	manivannan.sadhasivam, miquel.raynal, richard, vigneshr,
	andersson, konradybcio, agross
  Cc: linux-arm-msm, dmaengine, devicetree, linux-kernel, linux-mtd



On 3/13/2025 8:06 PM, Konrad Dybcio wrote:
> On 3/13/25 2:09 PM, Kaushal Kumar wrote:
>> Add devicetree node to enable support for QPIC
>> NAND controller on Qualcomm SDX75 platform.
>> Since there is no "aon" clock in SDX75, a dummy
>> clock is provided.
> Alter the bindings not to require it then, instead
>
> [...]
Will update in v2.
>
>>   
>> +		qpic_nand: nand-controller@1cc8000 {
>> +			compatible = "qcom,sdx75-nand", "qcom,sdx55-nand";
>> +			reg = <0x0 0x01cc8000 0x0 0x10000>;
>> +			#address-cells = <1>;
>> +			#size-cells = <0>;
>> +			clocks = <&rpmhcc RPMH_QPIC_CLK>,
>> +				 <&nand_clk_dummy>;
>> +			clock-names = "core", "aon";
>> +
>> +			dmas = <&qpic_bam 0>,
>> +			       <&qpic_bam 1>,
>> +			       <&qpic_bam 2>;
>> +			dma-names = "tx", "rx", "cmd";
> Please make dma-names a vertical list, just like dmas
Sure, will update in v2.
>
> Konrad


^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2025-03-27 10:48 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-13 13:09 [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Kaushal Kumar
2025-03-13 13:09 ` [PATCH 1/6] dt-bindings: mtd: qcom,nandc: Document the SDX75 NAND Kaushal Kumar
2025-03-13 14:31   ` Rob Herring (Arm)
2025-03-13 14:48   ` Krzysztof Kozlowski
2025-03-27 10:42     ` Kaushal Kumar
2025-03-13 13:09 ` [PATCH 2/6] dt-bindings: dma: qcom,bam: Document dma-coherent property Kaushal Kumar
2025-03-13 14:50   ` Krzysztof Kozlowski
2025-03-27 10:46     ` Kaushal Kumar
2025-03-13 13:09 ` [PATCH 3/6] ARM: dts: qcom: sdx75: Add QPIC BAM support Kaushal Kumar
2025-03-13 13:09 ` [PATCH 4/6] ARM: dts: qcom: sdx75: Add QPIC NAND support Kaushal Kumar
2025-03-13 14:36   ` Konrad Dybcio
2025-03-27 10:48     ` Kaushal Kumar
2025-03-13 14:50   ` Krzysztof Kozlowski
2025-03-27 10:47     ` Kaushal Kumar
2025-03-13 13:09 ` [PATCH 5/6] ARM: dts: qcom: sdx75-idp: Enable QPIC BAM support Kaushal Kumar
2025-03-13 14:37   ` Konrad Dybcio
2025-03-27 10:25     ` Kaushal Kumar
2025-03-13 13:09 ` [PATCH 6/6] ARM: dts: qcom: sdx75-idp: Enable QPIC NAND support Kaushal Kumar
2025-03-13 14:30 ` [PATCH 0/6] Enable QPIC BAM and QPIC NAND support for SDX75 Konrad Dybcio
2025-03-27 10:23   ` Kaushal Kumar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).