xref: /linux/Documentation/devicetree/bindings/mmc/socionext,uniphier-sd.yaml (revision 1136fa0c07de570dc17858745af8be169d1440ba)
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  dmas:
30    maxItems: 1
31
32  dma-names:
33    const: rx-tx
34
35  reset-names:
36    description: |
37      There are three reset signals at maximum
38        host:   mandatory for all variants
39        bridge: exist only for version 2.91
40        hw:     optional. exist if eMMC hw reset line is available
41    oneOf:
42      - const: host
43      - items:
44          - const: host
45          - const: bridge
46      - items:
47          - const: host
48          - const: hw
49      - items:
50          - const: host
51          - const: bridge
52          - const: hw
53
54  resets:
55    minItems: 1
56    maxItems: 3
57
58allOf:
59  - $ref: mmc-controller.yaml
60
61  - if:
62      properties:
63        compatible:
64          contains:
65            const: socionext,uniphier-sd-v2.91
66    then:
67      properties:
68        reset-names:
69          contains:
70            const: bridge
71    else:
72      properties:
73        reset-names:
74          not:
75            contains:
76              const: bridge
77
78required:
79  - compatible
80  - reg
81  - interrupts
82  - clocks
83  - reset-names
84  - resets
85
86unevaluatedProperties: false
87
88examples:
89  - |
90    sd: mmc@5a400000 {
91        compatible = "socionext,uniphier-sd-v2.91";
92        reg = <0x5a400000 0x200>;
93        interrupts = <0 76 4>;
94        pinctrl-names = "default", "uhs";
95        pinctrl-0 = <&pinctrl_sd>;
96        pinctrl-1 = <&pinctrl_sd_uhs>;
97        clocks = <&mio_clk 0>;
98        reset-names = "host", "bridge";
99        resets = <&mio_rst 0>, <&mio_rst 3>;
100        dma-names = "rx-tx";
101        dmas = <&dmac 4>;
102        bus-width = <4>;
103        cap-sd-highspeed;
104        sd-uhs-sdr12;
105        sd-uhs-sdr25;
106        sd-uhs-sdr50;
107    };
108