Skip to contentSkip to conversation

Convert QSPI binding to YAML and add interconnect doc

PATCH Applied Akash Asthana 2 participants 5 messages Mar 13, 2020 – Mar 30, 2020

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

v2 cover Convert QSPI binding to YAML and add interconnect doc

Akash Asthana (2):
dt-bindings: spi: Convert QSPI bindings to YAML
dt-bindings: spi: Add interconnect binding for QSPI

 .../devicetree/bindings/spi/qcom,spi-qcom-qspi.txt | 36 ---------
 .../bindings/spi/qcom,spi-qcom-qspi.yaml           | 88 ++++++++++++++++++++++
 2 files changed, 88 insertions(+), 36 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.txt
 create mode 100644 Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.yaml
Signature · 1 line
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,\na Linux Foundation Collaborative Project
#1 lore raw

PATCH v2 1/2 dt-bindings: spi: Convert QSPI bindings to YAML

Convert QSPI bindings to DT schema format using json-schema.

---
Changes in V2:
- As per Stephen's comment, dropped properties "#address-cells" & "#size-cells" from QSPI node as it's already defined in $ref: /spi/spi-controller.yaml#.
- As per Stephen's comment, dropped description for reg property and answered few Nitpicks.

 .../devicetree/bindings/spi/qcom,spi-qcom-qspi.txt | 36 ----------
 .../bindings/spi/qcom,spi-qcom-qspi.yaml           | 79 ++++++++++++++++++++++
 2 files changed, 79 insertions(+), 36 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.txt
 create mode 100644 Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.yaml
Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.txt deleted +0 -36
deleted file mode 100644
index 1d64b61..0000000
@@ -1,36 +0,0 @@
-Qualcomm Quad Serial Peripheral Interface (QSPI)
-
-The QSPI controller allows SPI protocol communication in single, dual, or quad
-wire transmission modes for read/write access to slaves such as NOR flash.
-
-Required properties:
-- compatible:	An SoC specific identifier followed by "qcom,qspi-v1", such as
-		"qcom,sdm845-qspi", "qcom,qspi-v1"
-- reg:		Should contain the base register location and length.
-- interrupts:	Interrupt number used by the controller.
-- clocks:	Should contain the core and AHB clock.
-- clock-names:	Should be "core" for core clock and "iface" for AHB clock.
-
-SPI slave nodes must be children of the SPI master node and can contain
-properties described in Documentation/devicetree/bindings/spi/spi-bus.txt
-
-Example:
-
-	qspi: spi@88df000 {
-		compatible = "qcom,sdm845-qspi", "qcom,qspi-v1";
-		reg = <0x88df000 0x600>;
-		#address-cells = <1>;
-		#size-cells = <0>;
-		interrupts = <GIC_SPI 82 IRQ_TYPE_LEVEL_HIGH>;
-		clock-names = "iface", "core";
-		clocks = <&gcc GCC_QSPI_CNOC_PERIPH_AHB_CLK>,
-			 <&gcc GCC_QSPI_CORE_CLK>;
-
-		flash@0 {
-			compatible = "jedec,spi-nor";
-			reg = <0>;
-			spi-max-frequency = <25000000>;
-			spi-tx-bus-width = <2>;
-			spi-rx-bus-width = <2>;
-		};
-	};
Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.yaml new file +79 -0

79 lines not on this page · raw message

Signature · 1 line
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,\na Linux Foundation Collaborative Project
maintainer Applied
#2 lore raw

Re: [PATCH V2 1/2] dt-bindings: spi: Convert QSPI bindings to YAML

Quoted 11 lines · Akash Asthana

Convert QSPI bindings to DT schema format using json-schema.

---
Changes in V2:
- As per Stephen's comment, dropped properties "#address-cells" & "#size-cells" from QSPI node as it's already defined in $ref: /spi/spi-controller.yaml#.
- As per Stephen's comment, dropped description for reg property and answered few Nitpicks.

Quoted 6 lines
 .../devicetree/bindings/spi/qcom,spi-qcom-qspi.txt | 36 ----------
 .../bindings/spi/qcom,spi-qcom-qspi.yaml           | 79 ++++++++++++++++++++++
 2 files changed, 79 insertions(+), 36 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.txt
 create mode 100644 Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.yaml

Applied, thanks.

Rob

#3 lore raw

PATCH v2 2/2 dt-bindings: spi: Add interconnect binding for QSPI

In reply to Akash Asthana

Add documentation for the interconnect and interconnect-names properties for QSPI.

---
Changes in V2:
- Added minItems = 1 for interconnect property

 Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.yaml | 9 +++++++++
 1 file changed, 9 insertions(+)
Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.yaml +9 -0
index 9582d37..0cf470e 100644
@@ -40,6 +40,15 @@ properties:
       - description: AHB clock
       - description: QSPI core clock
 
+  interconnects:
+    minItems: 1
+    maxItems: 2
+
+  interconnect-names:
+    items:
+      - const: qspi-config
+      - const: qspi-memory
+
 required:
   - compatible
   - reg
Signature · 1 line
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,\na Linux Foundation Collaborative Project
maintainer Applied
#4 lore raw

Re: [PATCH V2 2/2] dt-bindings: spi: Add interconnect binding for QSPI

Quoted 11 lines · Akash Asthana

Add documentation for the interconnect and interconnect-names properties for QSPI.

---
Changes in V2:
- Added minItems = 1 for interconnect property

 Documentation/devicetree/bindings/spi/qcom,spi-qcom-qspi.yaml | 9 +++++++++
 1 file changed, 9 insertions(+)

Applied, thanks.

Rob