devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v4 0/4] SDM670 GPI DMA support
@ 2022-10-01 21:19 Richard Acayan
  2022-10-01 21:19 ` [PATCH v4 1/4] dt-bindings: dma: qcom: gpi: add fallback compatible Richard Acayan
                   ` (4 more replies)
  0 siblings, 5 replies; 8+ messages in thread
From: Richard Acayan @ 2022-10-01 21:19 UTC (permalink / raw)
  To: linux-arm-msm
  Cc: Andy Gross, Bjorn Andersson, Konrad Dybcio, Vinod Koul,
	Rob Herring, Krzysztof Kozlowski, dmaengine, devicetree,
	Richard Acayan

Changes since v3:
 - keep other compatible strings in driver and add comment
 - accumulate review tags

Changes since v2:
 - change fallback to sdm845 compat string (and keep compat string in
   driver)
 - fallback now only affects two SoCs + SDM670

Changes since v1:
 - add fallback compatible

This patch series adds the compatible string for GPI DMA, needed for the
GENI interface, on Snapdragon 670.

Richard Acayan (4):
  dt-bindings: dma: qcom: gpi: add fallback compatible
  dt-bindings: dma: qcom: gpi: add compatible for sdm670
  arm64: dts: qcom: add gpi-dma fallback compatible
  dmaengine: qcom: deprecate redundant of_device_id entries

 .../devicetree/bindings/dma/qcom,gpi.yaml     | 22 ++++++++++++-------
 arch/arm64/boot/dts/qcom/sm8150.dtsi          |  6 ++---
 arch/arm64/boot/dts/qcom/sm8250.dtsi          |  6 ++---
 drivers/dma/qcom/gpi.c                        |  4 ++++
 4 files changed, 24 insertions(+), 14 deletions(-)

-- 
2.37.3


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

* [PATCH v4 1/4] dt-bindings: dma: qcom: gpi: add fallback compatible
  2022-10-01 21:19 [PATCH v4 0/4] SDM670 GPI DMA support Richard Acayan
@ 2022-10-01 21:19 ` Richard Acayan
  2022-10-01 21:19 ` [PATCH v4 2/4] dt-bindings: dma: qcom: gpi: add compatible for sdm670 Richard Acayan
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 8+ messages in thread
From: Richard Acayan @ 2022-10-01 21:19 UTC (permalink / raw)
  To: linux-arm-msm
  Cc: Andy Gross, Bjorn Andersson, Konrad Dybcio, Vinod Koul,
	Rob Herring, Krzysztof Kozlowski, dmaengine, devicetree,
	Richard Acayan

The drivers are transitioning from matching against lists of specific
compatible strings to matching against smaller lists of more generic
compatible strings. Use the SDM845 compatible string as a fallback in
the schema to support this change.

Signed-off-by: Richard Acayan <mailingradian@gmail.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 .../devicetree/bindings/dma/qcom,gpi.yaml     | 21 ++++++++++++-------
 1 file changed, 13 insertions(+), 8 deletions(-)

diff --git a/Documentation/devicetree/bindings/dma/qcom,gpi.yaml b/Documentation/devicetree/bindings/dma/qcom,gpi.yaml
index eabf8a76d3a0..081b8a2d393d 100644
--- a/Documentation/devicetree/bindings/dma/qcom,gpi.yaml
+++ b/Documentation/devicetree/bindings/dma/qcom,gpi.yaml
@@ -18,14 +18,19 @@ allOf:
 
 properties:
   compatible:
-    enum:
-      - qcom,sc7280-gpi-dma
-      - qcom,sdm845-gpi-dma
-      - qcom,sm6350-gpi-dma
-      - qcom,sm8150-gpi-dma
-      - qcom,sm8250-gpi-dma
-      - qcom,sm8350-gpi-dma
-      - qcom,sm8450-gpi-dma
+    oneOf:
+      - enum:
+          - qcom,sc7280-gpi-dma
+          - qcom,sdm845-gpi-dma
+          - qcom,sm6350-gpi-dma
+          - qcom,sm8350-gpi-dma
+          - qcom,sm8450-gpi-dma
+
+      - items:
+          - enum:
+              - qcom,sm8150-gpi-dma
+              - qcom,sm8250-gpi-dma
+          - const: qcom,sdm845-gpi-dma
 
   reg:
     maxItems: 1
-- 
2.37.3


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

* [PATCH v4 2/4] dt-bindings: dma: qcom: gpi: add compatible for sdm670
  2022-10-01 21:19 [PATCH v4 0/4] SDM670 GPI DMA support Richard Acayan
  2022-10-01 21:19 ` [PATCH v4 1/4] dt-bindings: dma: qcom: gpi: add fallback compatible Richard Acayan
@ 2022-10-01 21:19 ` Richard Acayan
  2022-10-01 21:19 ` [PATCH v4 3/4] arm64: dts: qcom: add gpi-dma fallback compatible Richard Acayan
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 8+ messages in thread
From: Richard Acayan @ 2022-10-01 21:19 UTC (permalink / raw)
  To: linux-arm-msm
  Cc: Andy Gross, Bjorn Andersson, Konrad Dybcio, Vinod Koul,
	Rob Herring, Krzysztof Kozlowski, dmaengine, devicetree,
	Richard Acayan

The Snapdragon 670 uses GPI DMA for its GENI interface. Add a compatible
string for it in the documentation.

Signed-off-by: Richard Acayan <mailingradian@gmail.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 Documentation/devicetree/bindings/dma/qcom,gpi.yaml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/dma/qcom,gpi.yaml b/Documentation/devicetree/bindings/dma/qcom,gpi.yaml
index 081b8a2d393d..750b40c32213 100644
--- a/Documentation/devicetree/bindings/dma/qcom,gpi.yaml
+++ b/Documentation/devicetree/bindings/dma/qcom,gpi.yaml
@@ -28,6 +28,7 @@ properties:
 
       - items:
           - enum:
+              - qcom,sdm670-gpi-dma
               - qcom,sm8150-gpi-dma
               - qcom,sm8250-gpi-dma
           - const: qcom,sdm845-gpi-dma
-- 
2.37.3


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

* [PATCH v4 3/4] arm64: dts: qcom: add gpi-dma fallback compatible
  2022-10-01 21:19 [PATCH v4 0/4] SDM670 GPI DMA support Richard Acayan
  2022-10-01 21:19 ` [PATCH v4 1/4] dt-bindings: dma: qcom: gpi: add fallback compatible Richard Acayan
  2022-10-01 21:19 ` [PATCH v4 2/4] dt-bindings: dma: qcom: gpi: add compatible for sdm670 Richard Acayan
@ 2022-10-01 21:19 ` Richard Acayan
  2022-10-01 21:20   ` Konrad Dybcio
  2022-10-01 21:19 ` [PATCH v4 4/4] dmaengine: qcom: deprecate redundant of_device_id entries Richard Acayan
  2022-10-18  3:05 ` (subset) [PATCH v4 0/4] SDM670 GPI DMA support Bjorn Andersson
  4 siblings, 1 reply; 8+ messages in thread
From: Richard Acayan @ 2022-10-01 21:19 UTC (permalink / raw)
  To: linux-arm-msm
  Cc: Andy Gross, Bjorn Andersson, Konrad Dybcio, Vinod Koul,
	Rob Herring, Krzysztof Kozlowski, dmaengine, devicetree,
	Richard Acayan

The dt schema for gpi-dma has been updated with a new fallback
compatible string. Add the compatible strings to existing device trees.

Signed-off-by: Richard Acayan <mailingradian@gmail.com>
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 arch/arm64/boot/dts/qcom/sm8150.dtsi | 6 +++---
 arch/arm64/boot/dts/qcom/sm8250.dtsi | 6 +++---
 2 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/sm8150.dtsi b/arch/arm64/boot/dts/qcom/sm8150.dtsi
index cef8c4f4f0ff..281d5109ac3b 100644
--- a/arch/arm64/boot/dts/qcom/sm8150.dtsi
+++ b/arch/arm64/boot/dts/qcom/sm8150.dtsi
@@ -887,7 +887,7 @@ gcc: clock-controller@100000 {
 		};
 
 		gpi_dma0: dma-controller@800000 {
-			compatible = "qcom,sm8150-gpi-dma";
+			compatible = "qcom,sm8150-gpi-dma", "qcom,sdm845-gpi-dma";
 			reg = <0 0x800000 0 0x60000>;
 			interrupts = <GIC_SPI 244 IRQ_TYPE_LEVEL_HIGH>,
 				     <GIC_SPI 245 IRQ_TYPE_LEVEL_HIGH>,
@@ -1222,7 +1222,7 @@ spi7: spi@89c000 {
 		};
 
 		gpi_dma1: dma-controller@a00000 {
-			compatible = "qcom,sm8150-gpi-dma";
+			compatible = "qcom,sm8150-gpi-dma", "qcom,sdm845-gpi-dma";
 			reg = <0 0xa00000 0 0x60000>;
 			interrupts = <GIC_SPI 279 IRQ_TYPE_LEVEL_HIGH>,
 				     <GIC_SPI 280 IRQ_TYPE_LEVEL_HIGH>,
@@ -1471,7 +1471,7 @@ spi16: spi@a94000 {
 		};
 
 		gpi_dma2: dma-controller@c00000 {
-			compatible = "qcom,sm8150-gpi-dma";
+			compatible = "qcom,sm8150-gpi-dma", "qcom,sdm845-gpi-dma";
 			reg = <0 0xc00000 0 0x60000>;
 			interrupts = <GIC_SPI 588 IRQ_TYPE_LEVEL_HIGH>,
 				     <GIC_SPI 589 IRQ_TYPE_LEVEL_HIGH>,
diff --git a/arch/arm64/boot/dts/qcom/sm8250.dtsi b/arch/arm64/boot/dts/qcom/sm8250.dtsi
index a5b62cadb129..5d5de7eead08 100644
--- a/arch/arm64/boot/dts/qcom/sm8250.dtsi
+++ b/arch/arm64/boot/dts/qcom/sm8250.dtsi
@@ -936,7 +936,7 @@ rng: rng@793000 {
 		};
 
 		gpi_dma2: dma-controller@800000 {
-			compatible = "qcom,sm8250-gpi-dma";
+			compatible = "qcom,sm8250-gpi-dma", "qcom,sdm845-gpi-dma";
 			reg = <0 0x00800000 0 0x70000>;
 			interrupts = <GIC_SPI 588 IRQ_TYPE_LEVEL_HIGH>,
 				     <GIC_SPI 589 IRQ_TYPE_LEVEL_HIGH>,
@@ -1187,7 +1187,7 @@ spi19: spi@894000 {
 		};
 
 		gpi_dma0: dma-controller@900000 {
-			compatible = "qcom,sm8250-gpi-dma";
+			compatible = "qcom,sm8250-gpi-dma", "qcom,sdm845-gpi-dma";
 			reg = <0 0x00900000 0 0x70000>;
 			interrupts = <GIC_SPI 244 IRQ_TYPE_LEVEL_HIGH>,
 				     <GIC_SPI 245 IRQ_TYPE_LEVEL_HIGH>,
@@ -1505,7 +1505,7 @@ spi7: spi@99c000 {
 		};
 
 		gpi_dma1: dma-controller@a00000 {
-			compatible = "qcom,sm8250-gpi-dma";
+			compatible = "qcom,sm8250-gpi-dma", "qcom,sdm845-gpi-dma";
 			reg = <0 0x00a00000 0 0x70000>;
 			interrupts = <GIC_SPI 279 IRQ_TYPE_LEVEL_HIGH>,
 				     <GIC_SPI 280 IRQ_TYPE_LEVEL_HIGH>,
-- 
2.37.3


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

* [PATCH v4 4/4] dmaengine: qcom: deprecate redundant of_device_id entries
  2022-10-01 21:19 [PATCH v4 0/4] SDM670 GPI DMA support Richard Acayan
                   ` (2 preceding siblings ...)
  2022-10-01 21:19 ` [PATCH v4 3/4] arm64: dts: qcom: add gpi-dma fallback compatible Richard Acayan
@ 2022-10-01 21:19 ` Richard Acayan
  2022-10-02  8:09   ` Krzysztof Kozlowski
  2022-10-18  3:05 ` (subset) [PATCH v4 0/4] SDM670 GPI DMA support Bjorn Andersson
  4 siblings, 1 reply; 8+ messages in thread
From: Richard Acayan @ 2022-10-01 21:19 UTC (permalink / raw)
  To: linux-arm-msm
  Cc: Andy Gross, Bjorn Andersson, Konrad Dybcio, Vinod Koul,
	Rob Herring, Krzysztof Kozlowski, dmaengine, devicetree,
	Richard Acayan

The drivers are transitioning from matching against lists of specific
compatible strings to matching against smaller lists of more generic
compatible strings. Add a message that the compatible strings with an
ee_offset of 0 are deprecated except for the SDM845 compatible string.

Signed-off-by: Richard Acayan <mailingradian@gmail.com>
---
 drivers/dma/qcom/gpi.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/dma/qcom/gpi.c b/drivers/dma/qcom/gpi.c
index 89839864b4ec..ff22f5725ded 100644
--- a/drivers/dma/qcom/gpi.c
+++ b/drivers/dma/qcom/gpi.c
@@ -2289,6 +2289,10 @@ static const struct of_device_id gpi_of_match[] = {
 	{ .compatible = "qcom,sc7280-gpi-dma", .data = (void *)0x10000 },
 	{ .compatible = "qcom,sdm845-gpi-dma", .data = (void *)0x0 },
 	{ .compatible = "qcom,sm6350-gpi-dma", .data = (void *)0x10000 },
+	/*
+	 * Deprecated, devices with ee_offset = 0 should use sdm845-gpi-dma as
+	 * fallback and not need their own entries here.
+	 */
 	{ .compatible = "qcom,sm8150-gpi-dma", .data = (void *)0x0 },
 	{ .compatible = "qcom,sm8250-gpi-dma", .data = (void *)0x0 },
 	{ .compatible = "qcom,sm8350-gpi-dma", .data = (void *)0x10000 },
-- 
2.37.3


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

* Re: [PATCH v4 3/4] arm64: dts: qcom: add gpi-dma fallback compatible
  2022-10-01 21:19 ` [PATCH v4 3/4] arm64: dts: qcom: add gpi-dma fallback compatible Richard Acayan
@ 2022-10-01 21:20   ` Konrad Dybcio
  0 siblings, 0 replies; 8+ messages in thread
From: Konrad Dybcio @ 2022-10-01 21:20 UTC (permalink / raw)
  To: Richard Acayan, linux-arm-msm
  Cc: Andy Gross, Bjorn Andersson, Vinod Koul, Rob Herring,
	Krzysztof Kozlowski, dmaengine, devicetree



On 1.10.2022 23:19, Richard Acayan wrote:
> The dt schema for gpi-dma has been updated with a new fallback
> compatible string. Add the compatible strings to existing device trees.
> 
> Signed-off-by: Richard Acayan <mailingradian@gmail.com>
> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
Reviewed-by: Konrad Dybcio <konrad.dybcio@somainline.org>

Konrad
>  arch/arm64/boot/dts/qcom/sm8150.dtsi | 6 +++---
>  arch/arm64/boot/dts/qcom/sm8250.dtsi | 6 +++---
>  2 files changed, 6 insertions(+), 6 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/qcom/sm8150.dtsi b/arch/arm64/boot/dts/qcom/sm8150.dtsi
> index cef8c4f4f0ff..281d5109ac3b 100644
> --- a/arch/arm64/boot/dts/qcom/sm8150.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sm8150.dtsi
> @@ -887,7 +887,7 @@ gcc: clock-controller@100000 {
>  		};
>  
>  		gpi_dma0: dma-controller@800000 {
> -			compatible = "qcom,sm8150-gpi-dma";
> +			compatible = "qcom,sm8150-gpi-dma", "qcom,sdm845-gpi-dma";
>  			reg = <0 0x800000 0 0x60000>;
>  			interrupts = <GIC_SPI 244 IRQ_TYPE_LEVEL_HIGH>,
>  				     <GIC_SPI 245 IRQ_TYPE_LEVEL_HIGH>,
> @@ -1222,7 +1222,7 @@ spi7: spi@89c000 {
>  		};
>  
>  		gpi_dma1: dma-controller@a00000 {
> -			compatible = "qcom,sm8150-gpi-dma";
> +			compatible = "qcom,sm8150-gpi-dma", "qcom,sdm845-gpi-dma";
>  			reg = <0 0xa00000 0 0x60000>;
>  			interrupts = <GIC_SPI 279 IRQ_TYPE_LEVEL_HIGH>,
>  				     <GIC_SPI 280 IRQ_TYPE_LEVEL_HIGH>,
> @@ -1471,7 +1471,7 @@ spi16: spi@a94000 {
>  		};
>  
>  		gpi_dma2: dma-controller@c00000 {
> -			compatible = "qcom,sm8150-gpi-dma";
> +			compatible = "qcom,sm8150-gpi-dma", "qcom,sdm845-gpi-dma";
>  			reg = <0 0xc00000 0 0x60000>;
>  			interrupts = <GIC_SPI 588 IRQ_TYPE_LEVEL_HIGH>,
>  				     <GIC_SPI 589 IRQ_TYPE_LEVEL_HIGH>,
> diff --git a/arch/arm64/boot/dts/qcom/sm8250.dtsi b/arch/arm64/boot/dts/qcom/sm8250.dtsi
> index a5b62cadb129..5d5de7eead08 100644
> --- a/arch/arm64/boot/dts/qcom/sm8250.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sm8250.dtsi
> @@ -936,7 +936,7 @@ rng: rng@793000 {
>  		};
>  
>  		gpi_dma2: dma-controller@800000 {
> -			compatible = "qcom,sm8250-gpi-dma";
> +			compatible = "qcom,sm8250-gpi-dma", "qcom,sdm845-gpi-dma";
>  			reg = <0 0x00800000 0 0x70000>;
>  			interrupts = <GIC_SPI 588 IRQ_TYPE_LEVEL_HIGH>,
>  				     <GIC_SPI 589 IRQ_TYPE_LEVEL_HIGH>,
> @@ -1187,7 +1187,7 @@ spi19: spi@894000 {
>  		};
>  
>  		gpi_dma0: dma-controller@900000 {
> -			compatible = "qcom,sm8250-gpi-dma";
> +			compatible = "qcom,sm8250-gpi-dma", "qcom,sdm845-gpi-dma";
>  			reg = <0 0x00900000 0 0x70000>;
>  			interrupts = <GIC_SPI 244 IRQ_TYPE_LEVEL_HIGH>,
>  				     <GIC_SPI 245 IRQ_TYPE_LEVEL_HIGH>,
> @@ -1505,7 +1505,7 @@ spi7: spi@99c000 {
>  		};
>  
>  		gpi_dma1: dma-controller@a00000 {
> -			compatible = "qcom,sm8250-gpi-dma";
> +			compatible = "qcom,sm8250-gpi-dma", "qcom,sdm845-gpi-dma";
>  			reg = <0 0x00a00000 0 0x70000>;
>  			interrupts = <GIC_SPI 279 IRQ_TYPE_LEVEL_HIGH>,
>  				     <GIC_SPI 280 IRQ_TYPE_LEVEL_HIGH>,

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

* Re: [PATCH v4 4/4] dmaengine: qcom: deprecate redundant of_device_id entries
  2022-10-01 21:19 ` [PATCH v4 4/4] dmaengine: qcom: deprecate redundant of_device_id entries Richard Acayan
@ 2022-10-02  8:09   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 8+ messages in thread
From: Krzysztof Kozlowski @ 2022-10-02  8:09 UTC (permalink / raw)
  To: Richard Acayan, linux-arm-msm
  Cc: Andy Gross, Bjorn Andersson, Konrad Dybcio, Vinod Koul,
	Rob Herring, Krzysztof Kozlowski, dmaengine, devicetree

On 01/10/2022 23:19, Richard Acayan wrote:
> The drivers are transitioning from matching against lists of specific
> compatible strings to matching against smaller lists of more generic
> compatible strings. Add a message that the compatible strings with an
> ee_offset of 0 are deprecated except for the SDM845 compatible string.
> 
> Signed-off-by: Richard Acayan <mailingradian@gmail.com>


Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>


Best regards,
Krzysztof


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

* Re: (subset) [PATCH v4 0/4] SDM670 GPI DMA support
  2022-10-01 21:19 [PATCH v4 0/4] SDM670 GPI DMA support Richard Acayan
                   ` (3 preceding siblings ...)
  2022-10-01 21:19 ` [PATCH v4 4/4] dmaengine: qcom: deprecate redundant of_device_id entries Richard Acayan
@ 2022-10-18  3:05 ` Bjorn Andersson
  4 siblings, 0 replies; 8+ messages in thread
From: Bjorn Andersson @ 2022-10-18  3:05 UTC (permalink / raw)
  To: linux-arm-msm, mailingradian
  Cc: dmaengine, devicetree, vkoul, robh+dt, agross,
	Krzysztof Kozlowski, Konrad Dybcio

On Sat, 1 Oct 2022 17:19:30 -0400, Richard Acayan wrote:
> Changes since v3:
>  - keep other compatible strings in driver and add comment
>  - accumulate review tags
> 
> Changes since v2:
>  - change fallback to sdm845 compat string (and keep compat string in
>    driver)
>  - fallback now only affects two SoCs + SDM670
> 
> [...]

Applied, thanks!

[3/4] arm64: dts: qcom: add gpi-dma fallback compatible
      commit: e7e24786cf904e22e0472ac9a5ad35bcbd3fb7a3

Best regards,
-- 
Bjorn Andersson <andersson@kernel.org>

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

end of thread, other threads:[~2022-10-18  3:12 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-10-01 21:19 [PATCH v4 0/4] SDM670 GPI DMA support Richard Acayan
2022-10-01 21:19 ` [PATCH v4 1/4] dt-bindings: dma: qcom: gpi: add fallback compatible Richard Acayan
2022-10-01 21:19 ` [PATCH v4 2/4] dt-bindings: dma: qcom: gpi: add compatible for sdm670 Richard Acayan
2022-10-01 21:19 ` [PATCH v4 3/4] arm64: dts: qcom: add gpi-dma fallback compatible Richard Acayan
2022-10-01 21:20   ` Konrad Dybcio
2022-10-01 21:19 ` [PATCH v4 4/4] dmaengine: qcom: deprecate redundant of_device_id entries Richard Acayan
2022-10-02  8:09   ` Krzysztof Kozlowski
2022-10-18  3:05 ` (subset) [PATCH v4 0/4] SDM670 GPI DMA support Bjorn Andersson

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).