Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

dt-bindings: mmc: ti,omap2430-sdhci: convert to DT schema

Convert TI OMAP SDHCI Controller binding to YAML format.
Changes during Conversion:
- Define new properties like "clocks", "clock-names",
"pbias-supply" and "power-domains" to resolve dtb_check errors.
- Remove "pinctrl-names" and "pinctrl-<n>"
from required as they are not necessary for all DTS files.
- Remove "ti,hwmods" property entirely from the YAML as the
DTS doesn't contain this property for the given compatibles and the
text binding is misleading.
- Add "clocks", "clock-names" and "max-frequency" to the required
properties based on the compatible and the text binding doesn't mention
these properties as required.
- Add missing strings like "default-rev11", "sdr12-rev11", "sdr25-rev11",
"hs-rev11", "sdr25-rev11" and "sleep" to pinctrl-names string array
to resolve errors detected by dtb_check.

Signed-off-by: Charan Pedumuru <charan.pedumuru@gmail.com>
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Link: https://lore.kernel.org/r/20251024-ti-sdhci-omap-v5-3-df5f6f033a38@gmail.com
Signed-off-by: Kevin Hilman <khilman@baylibre.com>

authored by

Charan Pedumuru and committed by
Kevin Hilman
333fa35f 9485ba8a

+169 -43
-43
Documentation/devicetree/bindings/mmc/sdhci-omap.txt
··· 1 - * TI OMAP SDHCI Controller 2 - 3 - Refer to mmc.txt for standard MMC bindings. 4 - 5 - For UHS devices which require tuning, the device tree should have a "cpu_thermal" node which maps to the appropriate thermal zone. This is used to get the temperature of the zone during tuning. 6 - 7 - Required properties: 8 - - compatible: Should be "ti,omap2430-sdhci" for omap2430 controllers 9 - Should be "ti,omap3-sdhci" for omap3 controllers 10 - Should be "ti,omap4-sdhci" for omap4 and ti81 controllers 11 - Should be "ti,omap5-sdhci" for omap5 controllers 12 - Should be "ti,dra7-sdhci" for DRA7 and DRA72 controllers 13 - Should be "ti,k2g-sdhci" for K2G 14 - Should be "ti,am335-sdhci" for am335x controllers 15 - Should be "ti,am437-sdhci" for am437x controllers 16 - - ti,hwmods: Must be "mmc<n>", <n> is controller instance starting 1 17 - (Not required for K2G). 18 - - pinctrl-names: Should be subset of "default", "hs", "sdr12", "sdr25", "sdr50", 19 - "ddr50-rev11", "sdr104-rev11", "ddr50", "sdr104", 20 - "ddr_1_8v-rev11", "ddr_1_8v" or "ddr_3_3v", "hs200_1_8v-rev11", 21 - "hs200_1_8v", 22 - - pinctrl-<n> : Pinctrl states as described in bindings/pinctrl/pinctrl-bindings.txt 23 - 24 - Optional properties: 25 - - dmas: List of DMA specifiers with the controller specific format as described 26 - in the generic DMA client binding. A tx and rx specifier is required. 27 - - dma-names: List of DMA request names. These strings correspond 1:1 with the 28 - DMA specifiers listed in dmas. The string naming is to be "tx" 29 - and "rx" for TX and RX DMA requests, respectively. 30 - 31 - Deprecated properties: 32 - - ti,non-removable: Compatible with the generic non-removable property 33 - 34 - Example: 35 - mmc1: mmc@4809c000 { 36 - compatible = "ti,dra7-sdhci"; 37 - reg = <0x4809c000 0x400>; 38 - ti,hwmods = "mmc1"; 39 - bus-width = <4>; 40 - vmmc-supply = <&vmmc>; /* phandle to regulator node */ 41 - dmas = <&sdma 61 &sdma 62>; 42 - dma-names = "tx", "rx"; 43 - };
+169
Documentation/devicetree/bindings/mmc/ti,omap2430-sdhci.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/mmc/ti,omap2430-sdhci.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: TI OMAP SDHCI Controller 8 + 9 + maintainers: 10 + - Kishon Vijay Abraham I <kishon@ti.com> 11 + 12 + description: 13 + For UHS devices which require tuning, the device tree should have a 14 + cpu_thermal node which maps to the appropriate thermal zone. This 15 + is used to get the temperature of the zone during tuning. 16 + 17 + properties: 18 + compatible: 19 + enum: 20 + - ti,omap2430-sdhci 21 + - ti,omap3-sdhci 22 + - ti,omap4-sdhci 23 + - ti,omap5-sdhci 24 + - ti,dra7-sdhci 25 + - ti,k2g-sdhci 26 + - ti,am335-sdhci 27 + - ti,am437-sdhci 28 + 29 + reg: 30 + maxItems: 1 31 + 32 + interrupts: 33 + maxItems: 1 34 + 35 + clocks: 36 + maxItems: 2 37 + 38 + clock-names: 39 + items: 40 + - const: fck 41 + - const: mmchsdb_fck 42 + 43 + dmas: 44 + maxItems: 2 45 + 46 + dma-names: 47 + items: 48 + - const: tx 49 + - const: rx 50 + 51 + pinctrl-names: 52 + minItems: 1 53 + maxItems: 14 54 + items: 55 + enum: 56 + - default 57 + - default-rev11 58 + - hs 59 + - sdr12 60 + - sdr12-rev11 61 + - sdr25 62 + - sdr25-rev11 63 + - sdr50 64 + - ddr50-rev11 65 + - sdr104-rev11 66 + - ddr50 67 + - sdr104 68 + - ddr_1_8v-rev11 69 + - ddr_1_8v 70 + - ddr_3_3v 71 + - hs-rev11 72 + - hs200_1_8v-rev11 73 + - hs200_1_8v 74 + - sleep 75 + 76 + pinctrl-0: 77 + maxItems: 1 78 + 79 + pinctrl-1: 80 + maxItems: 1 81 + 82 + pinctrl-2: 83 + maxItems: 1 84 + 85 + pinctrl-3: 86 + maxItems: 1 87 + 88 + pinctrl-4: 89 + maxItems: 1 90 + 91 + pinctrl-5: 92 + maxItems: 1 93 + 94 + pinctrl-6: 95 + maxItems: 1 96 + 97 + pinctrl-7: 98 + maxItems: 1 99 + 100 + pinctrl-8: 101 + maxItems: 1 102 + 103 + power-domains: 104 + maxItems: 1 105 + 106 + pbias-supply: 107 + description: 108 + It is used to specify the voltage regulator that provides the bias 109 + voltage for certain analog or I/O pads. 110 + 111 + ti,non-removable: 112 + description: 113 + It indicates that a component is not meant to be easily removed or 114 + replaced by the user, such as an embedded battery or a non-removable 115 + storage slot like eMMC. 116 + type: boolean 117 + deprecated: true 118 + 119 + clock-frequency: 120 + $ref: /schemas/types.yaml#/definitions/uint32 121 + description: 122 + It represents the speed at which a clock signal associated with a device 123 + or bus operates, measured in Hertz (Hz). This value is crucial for configuring 124 + hardware components that require a specific clock speed. 125 + 126 + required: 127 + - compatible 128 + - reg 129 + - interrupts 130 + 131 + allOf: 132 + - $ref: sdhci-common.yaml# 133 + - if: 134 + properties: 135 + compatible: 136 + contains: 137 + enum: 138 + - ti,dra7-sdhci 139 + - ti,k2g-sdhci 140 + then: 141 + required: 142 + - max-frequency 143 + - if: 144 + properties: 145 + compatible: 146 + contains: 147 + const: ti,k2g-sdhci 148 + then: 149 + required: 150 + - clocks 151 + - clock-names 152 + 153 + unevaluatedProperties: false 154 + 155 + examples: 156 + - | 157 + #include <dt-bindings/interrupt-controller/arm-gic.h> 158 + mmc@4809c000 { 159 + compatible = "ti,dra7-sdhci"; 160 + reg = <0x4809c000 0x400>; 161 + interrupts = <GIC_SPI 64 IRQ_TYPE_LEVEL_HIGH>; 162 + max-frequency = <192000000>; 163 + sdhci-caps-mask = <0x0 0x400000>; 164 + bus-width = <4>; 165 + vmmc-supply = <&vmmc>; /* phandle to regulator node */ 166 + dmas = <&sdma 61>, <&sdma 62>; 167 + dma-names = "tx", "rx"; 168 + }; 169 + ...