ARM: dts: ux500: Push VMMCI down to each tree
authorLinus Walleij <linus.walleij@linaro.org>
Sat, 19 Dec 2020 20:31:55 +0000 (21:31 +0100)
committerLinus Walleij <linus.walleij@linaro.org>
Wed, 13 Jan 2021 12:12:20 +0000 (13:12 +0100)
The setting of VMMCI differs so much between different
boards that we need to handle it on a per-board basis
rather that complicating things by overriding stuff from
the included DTSI:s. Push it down into top-level tree
instead.

Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
arch/arm/boot/dts/ste-href.dtsi
arch/arm/boot/dts/ste-href520-tvk.dts
arch/arm/boot/dts/ste-hrefprev60-stuib.dts
arch/arm/boot/dts/ste-hrefprev60-tvk.dts
arch/arm/boot/dts/ste-hrefprev60.dtsi
arch/arm/boot/dts/ste-hrefv60plus-stuib.dts
arch/arm/boot/dts/ste-hrefv60plus-tvk.dts
arch/arm/boot/dts/ste-hrefv60plus.dtsi

index ff47cbf6ed3b7c6b66298c7022f9f897f53de852..8c03124b69601f4dd88a636a2c92e8a80fed65d2 100644 (file)
                        status = "okay";
                };
 
-               /* ST6G3244ME level translator for 1.8/2.9 V */
-               vmmci: regulator-gpio {
-                       compatible = "regulator-gpio";
-
-                       regulator-min-microvolt = <1800000>;
-                       regulator-max-microvolt = <2900000>;
-                       regulator-name = "mmci-reg";
-                       regulator-type = "voltage";
-
-                       startup-delay-us = <100>;
-
-                       states = <1800000 0x1
-                                 2900000 0x0>;
-               };
-
                // External Micro SD slot
                sdi0_per1@80126000 {
                        arm,primecell-periphid = <0x10480180>;
index f8c0c1e6aa04bc5aa461b060683dba64373db47b..a036a03f67187eabf8318acd53de12b7cd529127 100644 (file)
        model = "ST-Ericsson HREF520 and TVK1281618 UIB";
        compatible = "st-ericsson,href520", "st-ericsson,u8500";
 
-       soc {
-               vmmci: regulator-gpio {
-                       gpios = <&gpio0 5 GPIO_ACTIVE_HIGH>;
-                       enable-gpio = <&gpio2 14 GPIO_ACTIVE_HIGH>;
-                       enable-active-high;
+
+       /* ST6G3244ME level translator for 1.8/2.9 V */
+       vmmci: regulator-gpio {
+               compatible = "regulator-gpio";
+
+               regulator-min-microvolt = <1800000>;
+               regulator-max-microvolt = <2900000>;
+               regulator-name = "mmci-reg";
+               regulator-type = "voltage";
+
+               startup-delay-us = <100>;
+
+               states = <1800000 0x1
+                         2900000 0x0>;
+
+               gpios = <&gpio0 5 GPIO_ACTIVE_HIGH>;
+               enable-gpio = <&gpio2 14 GPIO_ACTIVE_HIGH>;
+               enable-active-high;
+
+               pinctrl-names = "default";
+               pinctrl-0 = <&vmmci_default_mode>;
+       };
+};
+
+&pinctrl {
+       vmmci {
+               vmmci_default_mode: vmmc_default {
+                       /* VMMCI level-shifter enable */
+                       default_href520_cfg1 {
+                               pins = "GPIO78_F4";
+                               ste,config = <&gpio_out_hi>;
+                       };
+                       /* VMMCI level-shifter voltage select */
+                       default_href520_cfg2 {
+                               pins = "GPIO5_AG6";
+                               ste,config = <&gpio_out_hi>;
+                       };
                };
        };
 };
index 8ce6b723abf2480b10d2fda4d4c94ace510a738a..dfc933214c1a2be525d3e948010f9c9665c2c48f 100644 (file)
        model = "ST-Ericsson HREF (pre-v60) and ST UIB";
        compatible = "st-ericsson,mop500", "st-ericsson,u8500";
 
+       /* ST6G3244ME level translator for 1.8/2.9 V */
+       vmmci: regulator-gpio {
+               compatible = "regulator-gpio";
+
+               regulator-min-microvolt = <1800000>;
+               regulator-max-microvolt = <2900000>;
+               regulator-name = "mmci-reg";
+               regulator-type = "voltage";
+
+               startup-delay-us = <100>;
+
+               states = <1800000 0x1
+                         2900000 0x0>;
+
+               gpios = <&tc3589x_gpio 18 GPIO_ACTIVE_HIGH>;
+               enable-gpio = <&tc3589x_gpio 17 GPIO_ACTIVE_HIGH>;
+               enable-active-high;
+       };
+
        soc {
                /* Reset line for the BU21013 touchscreen */
                i2c@80110000 {
index 142f5475521f806742dd1fdfbbbbcd5a452f7f32..4e6e4439dcffc26920464b417db16a2ec49cde91 100644 (file)
 / {
        model = "ST-Ericsson HREF (pre-v60) and TVK1281618 UIB";
        compatible = "st-ericsson,mop500", "st-ericsson,u8500";
+
+       /* ST6G3244ME level translator for 1.8/2.9 V */
+       vmmci: regulator-gpio {
+               compatible = "regulator-gpio";
+
+               regulator-min-microvolt = <1800000>;
+               regulator-max-microvolt = <2900000>;
+               regulator-name = "mmci-reg";
+               regulator-type = "voltage";
+
+               startup-delay-us = <100>;
+
+               states = <1800000 0x1
+                         2900000 0x0>;
+
+               gpios = <&tc3589x_gpio 18 GPIO_ACTIVE_HIGH>;
+               enable-gpio = <&tc3589x_gpio 17 GPIO_ACTIVE_HIGH>;
+               enable-active-high;
+       };
 };
index 115495de8612810f4bfd6526a08a91bb34e3dc70..931998dd364b5477c0464761138cebfac335a904 100644 (file)
                        cd-gpios  = <&tc3589x_gpio 3 GPIO_ACTIVE_HIGH>;
                };
 
-               vmmci: regulator-gpio {
-                       gpios = <&tc3589x_gpio 18 GPIO_ACTIVE_HIGH>;
-                       enable-gpio = <&tc3589x_gpio 17 GPIO_ACTIVE_HIGH>;
-                       enable-active-high;
-               };
-
                pinctrl {
                        /* Set this up using hogs */
                        pinctrl-names = "default";
index 1316886e6bcb65583cd0870bc4b927e03b6fcce6..52c56ed17ae6882d6302f399b3dbd32f754d5f7f 100644 (file)
        model = "ST-Ericsson HREF (v60+) and ST UIB";
        compatible = "st-ericsson,hrefv60+", "st-ericsson,u8500";
 
+       /* ST6G3244ME level translator for 1.8/2.9 V */
+       vmmci: regulator-gpio {
+               compatible = "regulator-gpio";
+
+               regulator-min-microvolt = <1800000>;
+               regulator-max-microvolt = <2900000>;
+               regulator-name = "mmci-reg";
+               regulator-type = "voltage";
+
+               startup-delay-us = <100>;
+
+               states = <1800000 0x1
+                         2900000 0x0>;
+
+               gpios = <&gpio0 5 GPIO_ACTIVE_HIGH>;
+               enable-gpio = <&gpio5 9 GPIO_ACTIVE_HIGH>;
+               enable-active-high;
+
+               pinctrl-names = "default";
+               pinctrl-0 = <&vmmci_default_mode>;
+       };
+
        soc {
                /* Reset line for the BU21013 touchscreen */
                i2c@80110000 {
                };
        };
 };
+
+&pinctrl {
+       vmmci {
+               vmmci_default_mode: vmmc_default {
+                       /* VMMCI level-shifter enable */
+                       default_hrefv60_cfg2 {
+                               pins = "GPIO169_D22";
+                               ste,config = <&gpio_out_hi>;
+                       };
+                       /* VMMCI level-shifter voltage select */
+                       default_hrefv60_cfg3 {
+                               pins = "GPIO5_AG6";
+                               ste,config = <&gpio_out_hi>;
+                       };
+               };
+       };
+};
index 5d4b8245f02c089ad02f0e5b3633cea366dd0e48..9c2d2ee6d6d8d3699d91fd745b184a25153ab79b 100644 (file)
 / {
        model = "ST-Ericsson HREF (v60+) and TVK1281618 UIB";
        compatible = "st-ericsson,hrefv60+", "st-ericsson,u8500";
+
+       /* ST6G3244ME level translator for 1.8/2.9 V */
+       vmmci: regulator-gpio {
+               compatible = "regulator-gpio";
+
+               regulator-min-microvolt = <1800000>;
+               regulator-max-microvolt = <2900000>;
+               regulator-name = "mmci-reg";
+               regulator-type = "voltage";
+
+               startup-delay-us = <100>;
+
+               states = <1800000 0x1
+                         2900000 0x0>;
+
+               gpios = <&gpio0 5 GPIO_ACTIVE_HIGH>;
+               enable-gpio = <&gpio5 9 GPIO_ACTIVE_HIGH>;
+               enable-active-high;
+
+               pinctrl-names = "default";
+               pinctrl-0 = <&vmmci_default_mode>;
+       };
+};
+
+&pinctrl {
+       vmmci {
+               vmmci_default_mode: vmmc_default {
+                       /* VMMCI level-shifter enable */
+                       default_hrefv60_cfg2 {
+                               pins = "GPIO169_D22";
+                               ste,config = <&gpio_out_hi>;
+                       };
+                       /* VMMCI level-shifter voltage select */
+                       default_hrefv60_cfg3 {
+                               pins = "GPIO5_AG6";
+                               ste,config = <&gpio_out_hi>;
+                       };
+               };
+       };
 };
index ee0bf00a94b8a4ecc9bbe5ba059d08c1e5c2e1a7..05ea12e6df1c08dc57f1cb015a24197a21a8f3c1 100644 (file)
                        cd-gpios  = <&gpio2 31 GPIO_ACTIVE_HIGH>; // 95
                };
 
-               vmmci: regulator-gpio {
-                       gpios = <&gpio0 5 GPIO_ACTIVE_HIGH>;
-                       enable-gpio = <&gpio5 9 GPIO_ACTIVE_HIGH>;
-                       enable-active-high;
-               };
-
                pinctrl {
                        /*
                         * Set this up using hogs, as time goes by and as seems fit, these
                                                pins = "GPIO95_E8";
                                                ste,config = <&gpio_in_pu>;
                                        };
-                                       /* VMMCI level-shifter enable */
-                                       default_hrefv60_cfg2 {
-                                               pins = "GPIO169_D22";
-                                               ste,config = <&gpio_out_hi>;
-                                       };
-                                       /* VMMCI level-shifter voltage select */
-                                       default_hrefv60_cfg3 {
-                                               pins = "GPIO5_AG6";
-                                               ste,config = <&gpio_out_hi>;
-                                       };
                                };
                        };
                        ipgpio {