xref: /linux/Documentation/devicetree/bindings/mmc/socionext,uniphier-sd.yaml (revision f59cddd8517ab880fb09bf1465b07b337e058b22)
1# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
2%YAML 1.2
3---
4$id: http://devicetree.org/schemas/mmc/socionext,uniphier-sd.yaml#
5$schema: http://devicetree.org/meta-schemas/core.yaml#
6
7title: UniPhier SD/SDIO/eMMC controller
8
9maintainers:
10  - Masahiro Yamada <yamada.masahiro@socionext.com>
11
12properties:
13  compatible:
14    description: version 2.91, 3.1, 3.1.1, respectively
15    enum:
16      - socionext,uniphier-sd-v2.91
17      - socionext,uniphier-sd-v3.1
18      - socionext,uniphier-sd-v3.1.1
19
20  reg:
21    maxItems: 1
22
23  interrupts:
24    maxItems: 1
25
26  clocks:
27    maxItems: 1
28
29  reset-names:
30    description: |
31      There are three reset signals at maximum
32        host:   mandatory for all variants
33        bridge: exist only for version 2.91
34        hw:     optional. exist if eMMC hw reset line is available
35    oneOf:
36      - const: host
37      - items:
38          - const: host
39          - const: bridge
40      - items:
41          - const: host
42          - const: hw
43      - items:
44          - const: host
45          - const: bridge
46          - const: hw
47
48  resets:
49    minItems: 1
50    maxItems: 3
51
52allOf:
53  - $ref: mmc-controller.yaml
54
55  - if:
56      properties:
57        compatible:
58          contains:
59            const: socionext,uniphier-sd-v2.91
60    then:
61      properties:
62        reset-names:
63          contains:
64            const: bridge
65    else:
66      properties:
67        reset-names:
68          not:
69            contains:
70              const: bridge
71
72required:
73  - compatible
74  - reg
75  - interrupts
76  - clocks
77  - reset-names
78  - resets
79
80unevaluatedProperties: false
81
82examples:
83  - |
84    sd: mmc@5a400000 {
85        compatible = "socionext,uniphier-sd-v2.91";
86        reg = <0x5a400000 0x200>;
87        interrupts = <0 76 4>;
88        pinctrl-names = "default", "uhs";
89        pinctrl-0 = <&pinctrl_sd>;
90        pinctrl-1 = <&pinctrl_sd_uhs>;
91        clocks = <&mio_clk 0>;
92        reset-names = "host", "bridge";
93        resets = <&mio_rst 0>, <&mio_rst 3>;
94        dma-names = "rx-tx";
95        dmas = <&dmac 4>;
96        bus-width = <4>;
97        cap-sd-highspeed;
98        sd-uhs-sdr12;
99        sd-uhs-sdr25;
100        sd-uhs-sdr50;
101    };
102