xref: /freebsd/sys/contrib/device-tree/Bindings/mmc/sprd,sdhci-r11.yaml (revision 0e8011faf58b743cc652e3b2ad0f7671227610df)
1*0e8011faSEmmanuel Vadot# SPDX-License-Identifier: GPL-2.0 OR BSD-2-Clause
2*0e8011faSEmmanuel Vadot%YAML 1.2
3*0e8011faSEmmanuel Vadot---
4*0e8011faSEmmanuel Vadot$id: http://devicetree.org/schemas/mmc/sprd,sdhci-r11.yaml#
5*0e8011faSEmmanuel Vadot$schema: http://devicetree.org/meta-schemas/core.yaml#
6*0e8011faSEmmanuel Vadot
7*0e8011faSEmmanuel Vadottitle: Spreadtrum SDHCI controller
8*0e8011faSEmmanuel Vadot
9*0e8011faSEmmanuel Vadotmaintainers:
10*0e8011faSEmmanuel Vadot  - Orson Zhai <orsonzhai@gmail.com>
11*0e8011faSEmmanuel Vadot  - Baolin Wang <baolin.wang7@gmail.com>
12*0e8011faSEmmanuel Vadot  - Chunyan Zhang <zhang.lyra@gmail.com>
13*0e8011faSEmmanuel Vadot
14*0e8011faSEmmanuel Vadotproperties:
15*0e8011faSEmmanuel Vadot  compatible:
16*0e8011faSEmmanuel Vadot    const: sprd,sdhci-r11
17*0e8011faSEmmanuel Vadot
18*0e8011faSEmmanuel Vadot  reg:
19*0e8011faSEmmanuel Vadot    maxItems: 1
20*0e8011faSEmmanuel Vadot
21*0e8011faSEmmanuel Vadot  interrupts:
22*0e8011faSEmmanuel Vadot    maxItems: 1
23*0e8011faSEmmanuel Vadot
24*0e8011faSEmmanuel Vadot  clocks:
25*0e8011faSEmmanuel Vadot    minItems: 2
26*0e8011faSEmmanuel Vadot    items:
27*0e8011faSEmmanuel Vadot      - description: SDIO source clock
28*0e8011faSEmmanuel Vadot      - description: gate clock for enabling/disabling the device
29*0e8011faSEmmanuel Vadot      - description: gate clock controlling the device for some special platforms (optional)
30*0e8011faSEmmanuel Vadot
31*0e8011faSEmmanuel Vadot  clock-names:
32*0e8011faSEmmanuel Vadot    minItems: 2
33*0e8011faSEmmanuel Vadot    items:
34*0e8011faSEmmanuel Vadot      - const: sdio
35*0e8011faSEmmanuel Vadot      - const: enable
36*0e8011faSEmmanuel Vadot      - const: 2x_enable
37*0e8011faSEmmanuel Vadot
38*0e8011faSEmmanuel Vadot  pinctrl-0:
39*0e8011faSEmmanuel Vadot    description: default/high speed pin control
40*0e8011faSEmmanuel Vadot    maxItems: 1
41*0e8011faSEmmanuel Vadot
42*0e8011faSEmmanuel Vadot  pinctrl-1:
43*0e8011faSEmmanuel Vadot    description: UHS mode pin control
44*0e8011faSEmmanuel Vadot    maxItems: 1
45*0e8011faSEmmanuel Vadot
46*0e8011faSEmmanuel Vadot  pinctrl-names:
47*0e8011faSEmmanuel Vadot    minItems: 1
48*0e8011faSEmmanuel Vadot    items:
49*0e8011faSEmmanuel Vadot      - const: default
50*0e8011faSEmmanuel Vadot      - const: state_uhs
51*0e8011faSEmmanuel Vadot
52*0e8011faSEmmanuel VadotpatternProperties:
53*0e8011faSEmmanuel Vadot  "^sprd,phy-delay-(legacy|mmc-(ddr52|highspeed|hs[24]00|hs400es)|sd-(highspeed|uhs-sdr(50|104)))$":
54*0e8011faSEmmanuel Vadot    $ref: /schemas/types.yaml#/definitions/uint32-array
55*0e8011faSEmmanuel Vadot    items:
56*0e8011faSEmmanuel Vadot      - description: clock data write line delay value
57*0e8011faSEmmanuel Vadot      - description: clock read command line delay value
58*0e8011faSEmmanuel Vadot      - description: clock read data positive edge delay value
59*0e8011faSEmmanuel Vadot      - description: clock read data negative edge delay value
60*0e8011faSEmmanuel Vadot    description:
61*0e8011faSEmmanuel Vadot      PHY DLL delays are used to delay the data valid window, and align
62*0e8011faSEmmanuel Vadot      the window to the sampling clock. Each cell's delay value unit is
63*0e8011faSEmmanuel Vadot      cycle of the PHY clock.
64*0e8011faSEmmanuel Vadot
65*0e8011faSEmmanuel Vadotrequired:
66*0e8011faSEmmanuel Vadot  - compatible
67*0e8011faSEmmanuel Vadot  - reg
68*0e8011faSEmmanuel Vadot  - interrupts
69*0e8011faSEmmanuel Vadot  - clocks
70*0e8011faSEmmanuel Vadot  - clock-names
71*0e8011faSEmmanuel Vadot
72*0e8011faSEmmanuel VadotallOf:
73*0e8011faSEmmanuel Vadot  - $ref: sdhci-common.yaml#
74*0e8011faSEmmanuel Vadot
75*0e8011faSEmmanuel VadotunevaluatedProperties: false
76*0e8011faSEmmanuel Vadot
77*0e8011faSEmmanuel Vadotexamples:
78*0e8011faSEmmanuel Vadot  - |
79*0e8011faSEmmanuel Vadot    #include <dt-bindings/clock/sprd,sc9860-clk.h>
80*0e8011faSEmmanuel Vadot    #include <dt-bindings/interrupt-controller/arm-gic.h>
81*0e8011faSEmmanuel Vadot    #include <dt-bindings/interrupt-controller/irq.h>
82*0e8011faSEmmanuel Vadot
83*0e8011faSEmmanuel Vadot    mmc@50430000 {
84*0e8011faSEmmanuel Vadot      compatible = "sprd,sdhci-r11";
85*0e8011faSEmmanuel Vadot      reg = <0x50430000 0x1000>;
86*0e8011faSEmmanuel Vadot      interrupts = <GIC_SPI 41 IRQ_TYPE_LEVEL_HIGH>;
87*0e8011faSEmmanuel Vadot
88*0e8011faSEmmanuel Vadot      clocks = <&aon_prediv CLK_EMMC_2X>,
89*0e8011faSEmmanuel Vadot               <&apahb_gate CLK_EMMC_EB>,
90*0e8011faSEmmanuel Vadot               <&aon_gate CLK_EMMC_2X_EN>;
91*0e8011faSEmmanuel Vadot      clock-names = "sdio", "enable", "2x_enable";
92*0e8011faSEmmanuel Vadot
93*0e8011faSEmmanuel Vadot      pinctrl-0 = <&sd0_pins_default>;
94*0e8011faSEmmanuel Vadot      pinctrl-1 = <&sd0_pins_uhs>;
95*0e8011faSEmmanuel Vadot      pinctrl-names = "default", "state_uhs";
96*0e8011faSEmmanuel Vadot
97*0e8011faSEmmanuel Vadot      bus-width = <8>;
98*0e8011faSEmmanuel Vadot      cap-mmc-hw-reset;
99*0e8011faSEmmanuel Vadot      mmc-hs400-enhanced-strobe;
100*0e8011faSEmmanuel Vadot      mmc-hs400-1_8v;
101*0e8011faSEmmanuel Vadot      mmc-hs200-1_8v;
102*0e8011faSEmmanuel Vadot      mmc-ddr-1_8v;
103*0e8011faSEmmanuel Vadot      non-removable;
104*0e8011faSEmmanuel Vadot      no-sdio;
105*0e8011faSEmmanuel Vadot      no-sd;
106*0e8011faSEmmanuel Vadot
107*0e8011faSEmmanuel Vadot      sprd,phy-delay-mmc-ddr52 = <0x3f 0x75 0x14 0x14>;
108*0e8011faSEmmanuel Vadot      sprd,phy-delay-mmc-hs200 = <0x0 0x8c 0x8c 0x8c>;
109*0e8011faSEmmanuel Vadot      sprd,phy-delay-mmc-hs400 = <0x44 0x7f 0x2e 0x2e>;
110*0e8011faSEmmanuel Vadot      sprd,phy-delay-mmc-hs400es = <0x3f 0x3f 0x2e 0x2e>;
111*0e8011faSEmmanuel Vadot    };
112*0e8011faSEmmanuel Vadot...
113