Linux-libre 5.3.12-gnu
[librecmc/linux-libre.git] / Documentation / devicetree / bindings / mmc / nvidia,tegra20-sdhci.txt
1 * NVIDIA Tegra Secure Digital Host Controller
2
3 This controller on Tegra family SoCs provides an interface for MMC, SD,
4 and SDIO types of memory cards.
5
6 This file documents differences between the core properties described
7 by mmc.txt and the properties used by the sdhci-tegra driver.
8
9 Required properties:
10 - compatible : should be one of:
11   - "nvidia,tegra20-sdhci": for Tegra20
12   - "nvidia,tegra30-sdhci": for Tegra30
13   - "nvidia,tegra114-sdhci": for Tegra114
14   - "nvidia,tegra124-sdhci": for Tegra124 and Tegra132
15   - "nvidia,tegra210-sdhci": for Tegra210
16   - "nvidia,tegra186-sdhci": for Tegra186
17   - "nvidia,tegra194-sdhci": for Tegra194
18 - clocks : Must contain one entry, for the module clock.
19   See ../clocks/clock-bindings.txt for details.
20 - resets : Must contain an entry for each entry in reset-names.
21   See ../reset/reset.txt for details.
22 - reset-names : Must include the following entries:
23   - sdhci
24
25 Optional properties:
26 - power-gpios : Specify GPIOs for power control
27
28 Example:
29
30 sdhci@c8000200 {
31         compatible = "nvidia,tegra20-sdhci";
32         reg = <0xc8000200 0x200>;
33         interrupts = <47>;
34         clocks = <&tegra_car 14>;
35         resets = <&tegra_car 14>;
36         reset-names = "sdhci";
37         cd-gpios = <&gpio 69 0>; /* gpio PI5 */
38         wp-gpios = <&gpio 57 0>; /* gpio PH1 */
39         power-gpios = <&gpio 155 0>; /* gpio PT3 */
40         bus-width = <8>;
41 };
42
43 Optional properties for Tegra210, Tegra186 and Tegra194:
44 - pinctrl-names, pinctrl-0, pinctrl-1 : Specify pad voltage
45   configurations. Valid pinctrl-names are "sdmmc-3v3" and "sdmmc-1v8"
46   for controllers supporting multiple voltage levels. The order of names
47   should correspond to the pin configuration states in pinctrl-0 and
48   pinctrl-1.
49 - pinctrl-names : "sdmmc-3v3-drv" and "sdmmc-1v8-drv" are applicable for
50   Tegra210 where pad config registers are in the pinmux register domain
51   for pull-up-strength and pull-down-strength values configuration when
52   using pads at 3V3 and 1V8 levels.
53 - nvidia,only-1-8-v : The presence of this property indicates that the
54   controller operates at a 1.8 V fixed I/O voltage.
55 - nvidia,pad-autocal-pull-up-offset-3v3,
56   nvidia,pad-autocal-pull-down-offset-3v3 : Specify drive strength
57   calibration offsets for 3.3 V signaling modes.
58 - nvidia,pad-autocal-pull-up-offset-1v8,
59   nvidia,pad-autocal-pull-down-offset-1v8 : Specify drive strength
60   calibration offsets for 1.8 V signaling modes.
61 - nvidia,pad-autocal-pull-up-offset-3v3-timeout,
62   nvidia,pad-autocal-pull-down-offset-3v3-timeout : Specify drive
63   strength used as a fallback in case the automatic calibration times
64   out on a 3.3 V signaling mode.
65 - nvidia,pad-autocal-pull-up-offset-1v8-timeout,
66   nvidia,pad-autocal-pull-down-offset-1v8-timeout : Specify drive
67   strength used as a fallback in case the automatic calibration times
68   out on a 1.8 V signaling mode.
69 - nvidia,pad-autocal-pull-up-offset-sdr104,
70   nvidia,pad-autocal-pull-down-offset-sdr104 : Specify drive strength
71   calibration offsets for SDR104 mode.
72 - nvidia,pad-autocal-pull-up-offset-hs400,
73   nvidia,pad-autocal-pull-down-offset-hs400 : Specify drive strength
74   calibration offsets for HS400 mode.
75 - nvidia,default-tap : Specify the default inbound sampling clock
76   trimmer value for non-tunable modes.
77 - nvidia,default-trim : Specify the default outbound clock trimmer
78   value.
79 - nvidia,dqs-trim : Specify DQS trim value for HS400 timing
80
81   Notes on the pad calibration pull up and pulldown offset values:
82     - The property values are drive codes which are programmed into the
83       PD_OFFSET and PU_OFFSET sections of the
84       SDHCI_TEGRA_AUTO_CAL_CONFIG register.
85     - A higher value corresponds to higher drive strength. Please refer
86       to the reference manual of the SoC for correct values.
87     - The SDR104 and HS400 timing specific values are used in
88       corresponding modes if specified.
89
90   Notes on tap and trim values:
91     - The values are used for compensating trace length differences
92       by adjusting the sampling point.
93     - The values are programmed to the Vendor Clock Control Register.
94       Please refer to the reference manual of the SoC for correct
95       values.
96     - The DQS trim values are only used on controllers which support
97       HS400 timing. Only SDMMC4 on Tegra210 and Tegra 186 supports
98       HS400.
99
100 Example:
101 sdhci@700b0000 {
102         compatible = "nvidia,tegra210-sdhci", "nvidia,tegra124-sdhci";
103         reg = <0x0 0x700b0000 0x0 0x200>;
104         interrupts = <GIC_SPI 14 IRQ_TYPE_LEVEL_HIGH>;
105         clocks = <&tegra_car TEGRA210_CLK_SDMMC1>;
106         clock-names = "sdhci";
107         resets = <&tegra_car 14>;
108         reset-names = "sdhci";
109         pinctrl-names = "sdmmc-3v3", "sdmmc-1v8";
110         pinctrl-0 = <&sdmmc1_3v3>;
111         pinctrl-1 = <&sdmmc1_1v8>;
112         nvidia,pad-autocal-pull-up-offset-3v3 = <0x00>;
113         nvidia,pad-autocal-pull-down-offset-3v3 = <0x7d>;
114         nvidia,pad-autocal-pull-up-offset-1v8 = <0x7b>;
115         nvidia,pad-autocal-pull-down-offset-1v8 = <0x7b>;
116         status = "disabled";
117 };