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