xref: /freebsd/sys/contrib/device-tree/Bindings/spi/qcom,spi-qcom-qspi.yaml (revision f126890ac5386406dadf7c4cfa9566cbb56537c5)
1c66ec88fSEmmanuel Vadot# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2c66ec88fSEmmanuel Vadot%YAML 1.2
3c66ec88fSEmmanuel Vadot---
4cb7aa33aSEmmanuel Vadot$id: http://devicetree.org/schemas/spi/qcom,spi-qcom-qspi.yaml#
5cb7aa33aSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6c66ec88fSEmmanuel Vadot
7c66ec88fSEmmanuel Vadottitle: Qualcomm Quad Serial Peripheral Interface (QSPI)
8c66ec88fSEmmanuel Vadot
9c66ec88fSEmmanuel Vadotmaintainers:
10d5b0e70fSEmmanuel Vadot  - Bjorn Andersson <bjorn.andersson@linaro.org>
11c66ec88fSEmmanuel Vadot
12c66ec88fSEmmanuel Vadotdescription: The QSPI controller allows SPI protocol communication in single,
13c66ec88fSEmmanuel Vadot  dual, or quad wire transmission modes for read/write access to slaves such
14c66ec88fSEmmanuel Vadot  as NOR flash.
15c66ec88fSEmmanuel Vadot
16c66ec88fSEmmanuel VadotallOf:
17c9ccf3a3SEmmanuel Vadot  - $ref: /schemas/spi/spi-controller.yaml#
18c66ec88fSEmmanuel Vadot
19c66ec88fSEmmanuel Vadotproperties:
20c66ec88fSEmmanuel Vadot  compatible:
21c66ec88fSEmmanuel Vadot    items:
228cc087a1SEmmanuel Vadot      - enum:
238cc087a1SEmmanuel Vadot          - qcom,sc7180-qspi
248cc087a1SEmmanuel Vadot          - qcom,sc7280-qspi
258cc087a1SEmmanuel Vadot          - qcom,sdm845-qspi
268cc087a1SEmmanuel Vadot
27c66ec88fSEmmanuel Vadot      - const: qcom,qspi-v1
28c66ec88fSEmmanuel Vadot
29c66ec88fSEmmanuel Vadot  reg:
30c66ec88fSEmmanuel Vadot    maxItems: 1
31c66ec88fSEmmanuel Vadot
32*f126890aSEmmanuel Vadot  iommus:
33*f126890aSEmmanuel Vadot    maxItems: 1
34*f126890aSEmmanuel Vadot
35c66ec88fSEmmanuel Vadot  interrupts:
36c66ec88fSEmmanuel Vadot    maxItems: 1
37c66ec88fSEmmanuel Vadot
38c66ec88fSEmmanuel Vadot  clock-names:
39c66ec88fSEmmanuel Vadot    items:
40c66ec88fSEmmanuel Vadot      - const: iface
41c66ec88fSEmmanuel Vadot      - const: core
42c66ec88fSEmmanuel Vadot
43c66ec88fSEmmanuel Vadot  clocks:
44c66ec88fSEmmanuel Vadot    items:
45c66ec88fSEmmanuel Vadot      - description: AHB clock
46c66ec88fSEmmanuel Vadot      - description: QSPI core clock
47c66ec88fSEmmanuel Vadot
48c66ec88fSEmmanuel Vadot  interconnects:
49c66ec88fSEmmanuel Vadot    minItems: 1
50c66ec88fSEmmanuel Vadot    maxItems: 2
51c66ec88fSEmmanuel Vadot
52c66ec88fSEmmanuel Vadot  interconnect-names:
53d5b0e70fSEmmanuel Vadot    minItems: 1
54c66ec88fSEmmanuel Vadot    items:
55c66ec88fSEmmanuel Vadot      - const: qspi-config
56c66ec88fSEmmanuel Vadot      - const: qspi-memory
57c66ec88fSEmmanuel Vadot
58cb7aa33aSEmmanuel Vadot  operating-points-v2: true
59cb7aa33aSEmmanuel Vadot
60cb7aa33aSEmmanuel Vadot  power-domains:
61cb7aa33aSEmmanuel Vadot    maxItems: 1
62cb7aa33aSEmmanuel Vadot
63c66ec88fSEmmanuel Vadotrequired:
64c66ec88fSEmmanuel Vadot  - compatible
65c66ec88fSEmmanuel Vadot  - reg
66c66ec88fSEmmanuel Vadot  - interrupts
67c66ec88fSEmmanuel Vadot  - clock-names
68c66ec88fSEmmanuel Vadot  - clocks
69c66ec88fSEmmanuel Vadot
706be33864SEmmanuel VadotunevaluatedProperties: false
716be33864SEmmanuel Vadot
72c66ec88fSEmmanuel Vadotexamples:
73c66ec88fSEmmanuel Vadot  - |
74c66ec88fSEmmanuel Vadot    #include <dt-bindings/clock/qcom,gcc-sdm845.h>
75c66ec88fSEmmanuel Vadot    #include <dt-bindings/interrupt-controller/arm-gic.h>
76c66ec88fSEmmanuel Vadot
77c66ec88fSEmmanuel Vadot    soc: soc {
78c66ec88fSEmmanuel Vadot        #address-cells = <2>;
79c66ec88fSEmmanuel Vadot        #size-cells = <2>;
80c66ec88fSEmmanuel Vadot
81c66ec88fSEmmanuel Vadot        qspi: spi@88df000 {
82c66ec88fSEmmanuel Vadot            compatible = "qcom,sdm845-qspi", "qcom,qspi-v1";
83c66ec88fSEmmanuel Vadot            reg = <0 0x88df000 0 0x600>;
84c66ec88fSEmmanuel Vadot            #address-cells = <1>;
85c66ec88fSEmmanuel Vadot            #size-cells = <0>;
86c66ec88fSEmmanuel Vadot            interrupts = <GIC_SPI 82 IRQ_TYPE_LEVEL_HIGH>;
87c66ec88fSEmmanuel Vadot            clock-names = "iface", "core";
88c66ec88fSEmmanuel Vadot            clocks = <&gcc GCC_QSPI_CNOC_PERIPH_AHB_CLK>,
89c66ec88fSEmmanuel Vadot                         <&gcc GCC_QSPI_CORE_CLK>;
90c66ec88fSEmmanuel Vadot
91c66ec88fSEmmanuel Vadot            flash@0 {
92c66ec88fSEmmanuel Vadot                compatible = "jedec,spi-nor";
93c66ec88fSEmmanuel Vadot                reg = <0>;
94c66ec88fSEmmanuel Vadot                spi-max-frequency = <25000000>;
95c66ec88fSEmmanuel Vadot                spi-tx-bus-width = <2>;
96c66ec88fSEmmanuel Vadot                spi-rx-bus-width = <2>;
97c66ec88fSEmmanuel Vadot            };
98c66ec88fSEmmanuel Vadot        };
99c66ec88fSEmmanuel Vadot    };
100c66ec88fSEmmanuel Vadot...
101