devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] dt-bindings: spi: dw-apb-ssi: Integrate Renesas RZ/N1 SPI controller
@ 2021-05-06 11:52 Geert Uytterhoeven
  2021-05-07 22:13 ` Rob Herring
  2021-05-11  8:25 ` Mark Brown
  0 siblings, 2 replies; 3+ messages in thread
From: Geert Uytterhoeven @ 2021-05-06 11:52 UTC (permalink / raw)
  To: Mark Brown, Rob Herring, Serge Semin, Gareth Williams
  Cc: linux-spi, devicetree, linux-renesas-soc, Geert Uytterhoeven

Originally, the Renesas RZ/N1 SPI Controller DT bindings were not
integrated in the main DT bindings for the Synopsys DesignWare
Synchronous Serial Interface, but in its own file, as the RZ/N1
controller has additional registers for software CS control and DMA.

As so far DMA is not supported on RZ/N1, and json-schema can handle any
possible differences fine, integrate the RZ/N1 compatible values in the
main DT bindings for the Synopsys DW SSI.

Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
---
There are no upstream users of this binding, but it validates the
following (modified) example taken from the RZ/N1 BSP[1] fine:

    spi0: spi@50005000 {
	    compatible = "renesas,r9a06g032-spi", "renesas,rzn1-spi";
	    reg = <0x50005000 0x400>;
	    interrupts = <GIC_SPI 80 IRQ_TYPE_LEVEL_HIGH>;
	    clock-names = "ssi_clk", "pclk";
	    clocks = <&sysctrl R9A06G032_CLK_SPI0>, <&sysctrl R9A06G032_HCLK_SPI0>;
	    #address-cells = <1>;
	    #size-cells = <0>;
	    spi-max-frequency = <12500000>;
	    num-cs = <4>;
    };

[1] https://github.com/renesas-rz/rzn1_linux/blob/rzn1-stable-v4.19/arch/arm/boot/dts/rzn1.dtsi
---
 .../devicetree/bindings/spi/renesas,rzn1-spi.txt      | 11 -----------
 .../devicetree/bindings/spi/snps,dw-apb-ssi.yaml      |  6 ++++++
 2 files changed, 6 insertions(+), 11 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/spi/renesas,rzn1-spi.txt

diff --git a/Documentation/devicetree/bindings/spi/renesas,rzn1-spi.txt b/Documentation/devicetree/bindings/spi/renesas,rzn1-spi.txt
deleted file mode 100644
index fb1a6728638d3e2f..0000000000000000
--- a/Documentation/devicetree/bindings/spi/renesas,rzn1-spi.txt
+++ /dev/null
@@ -1,11 +0,0 @@
-Renesas RZ/N1 SPI Controller
-
-This controller is based on the Synopsys DW Synchronous Serial Interface and
-inherits all properties defined in snps,dw-apb-ssi.txt except for the
-compatible property.
-
-Required properties:
-- compatible : The device specific string followed by the generic RZ/N1 string.
-   Therefore it must be one of:
-   "renesas,r9a06g032-spi", "renesas,rzn1-spi"
-   "renesas,r9a06g033-spi", "renesas,rzn1-spi"
diff --git a/Documentation/devicetree/bindings/spi/snps,dw-apb-ssi.yaml b/Documentation/devicetree/bindings/spi/snps,dw-apb-ssi.yaml
index 4825157cd92e8262..ca91201a99269750 100644
--- a/Documentation/devicetree/bindings/spi/snps,dw-apb-ssi.yaml
+++ b/Documentation/devicetree/bindings/spi/snps,dw-apb-ssi.yaml
@@ -67,6 +67,12 @@ properties:
         const: baikal,bt1-sys-ssi
       - description: Canaan Kendryte K210 SoS SPI Controller
         const: canaan,k210-spi
+      - description: Renesas RZ/N1 SPI Controller
+        items:
+          - enum:
+              - renesas,r9a06g032-spi # RZ/N1D
+              - renesas,r9a06g033-spi # RZ/N1S
+          - const: renesas,rzn1-spi   # RZ/N1
 
   reg:
     minItems: 1
-- 
2.25.1


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

end of thread, other threads:[~2021-05-11  8:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-05-06 11:52 [PATCH] dt-bindings: spi: dw-apb-ssi: Integrate Renesas RZ/N1 SPI controller Geert Uytterhoeven
2021-05-07 22:13 ` Rob Herring
2021-05-11  8:25 ` Mark Brown

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