]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
imx7d-sdb: Sync devicetree with kernel 6.5-rc1
authorFabio Estevam <festevam@denx.de>
Wed, 13 Dec 2023 12:37:08 +0000 (09:37 -0300)
committerFabio Estevam <festevam@gmail.com>
Wed, 13 Dec 2023 12:38:28 +0000 (09:38 -0300)
Commit 0aea5dda2928 ("ARM: dts: imx7d-sdb-u-boot: Fix usdhc1 UHS
operation") did a temporary workaround by addng the usdhc1 fix
inside the -u-boot.dtsi file.

The imx7d-sdb.dts from kernel 6.5-rc1 contains the proper UHS
fix, so sync the devicetree tree and remove the previous fix
from -u-boot.dtsi.

Also, adjust the PMIC node name inside pmic_get() to match
the devicetree update.

Signed-off-by: Fabio Estevam <festevam@denx.de>
arch/arm/dts/imx7d-sdb-u-boot.dtsi
arch/arm/dts/imx7d-sdb.dts
board/freescale/mx7dsabresd/mx7dsabresd.c

index 71bfd80aab830cd8e4543779cf09e86487f034e4..eace17e052e925b0ad76b1dd2140ca8480887504 100644 (file)
        dr_mode = "peripheral";
 };
 
-&usdhc1 {
-       pinctrl-names = "default", "state_100mhz", "state_200mhz";
-       pinctrl-0 = <&pinctrl_usdhc1>, <&pinctrl_usdhc1_gpio>;
-       pinctrl-1 = <&pinctrl_usdhc1_100mhz>, <&pinctrl_usdhc1_gpio>;
-       pinctrl-2 = <&pinctrl_usdhc1_200mhz>, <&pinctrl_usdhc1_gpio>;
-};
-
-&pinctrl_usdhc1 {
-               fsl,pins = <
-                       MX7D_PAD_SD1_CMD__SD1_CMD               0x59
-                       MX7D_PAD_SD1_CLK__SD1_CLK               0x19
-                       MX7D_PAD_SD1_DATA0__SD1_DATA0           0x59
-                       MX7D_PAD_SD1_DATA1__SD1_DATA1           0x59
-                       MX7D_PAD_SD1_DATA2__SD1_DATA2           0x59
-                       MX7D_PAD_SD1_DATA3__SD1_DATA3           0x59
-               >;
-};
-
-&iomuxc {
-       pinctrl_usdhc1_gpio: usdhc1gpiogrp {
-               fsl,pins = <
-                       MX7D_PAD_SD1_CD_B__GPIO5_IO0            0x59 /* CD */
-                       MX7D_PAD_SD1_WP__GPIO5_IO1              0x59 /* WP */
-                       MX7D_PAD_SD1_RESET_B__GPIO5_IO2         0x59 /* vmmc */
-                       MX7D_PAD_GPIO1_IO08__SD1_VSELECT        0x59 /* VSELECT */
-               >;
-       };
-
-       pinctrl_usdhc1_100mhz: usdhc1100mhzgrp {
-               fsl,pins = <
-                       MX7D_PAD_SD1_CMD__SD1_CMD               0x5a
-                       MX7D_PAD_SD1_CLK__SD1_CLK               0x1a
-                       MX7D_PAD_SD1_DATA0__SD1_DATA0           0x5a
-                       MX7D_PAD_SD1_DATA1__SD1_DATA1           0x5a
-                       MX7D_PAD_SD1_DATA2__SD1_DATA2           0x5a
-                       MX7D_PAD_SD1_DATA3__SD1_DATA3           0x5a
-               >;
-       };
-
-       pinctrl_usdhc1_200mhz: usdhc1200mhzgrp {
-               fsl,pins = <
-                       MX7D_PAD_SD1_CMD__SD1_CMD               0x5b
-                       MX7D_PAD_SD1_CLK__SD1_CLK               0x1b
-                       MX7D_PAD_SD1_DATA0__SD1_DATA0           0x5b
-                       MX7D_PAD_SD1_DATA1__SD1_DATA1           0x5b
-                       MX7D_PAD_SD1_DATA2__SD1_DATA2           0x5b
-                       MX7D_PAD_SD1_DATA3__SD1_DATA3           0x5b
-               >;
-       };
-};
-
 &wdog1 {
        bootph-pre-ram;
 };
index 78f4224a9bf4eb5795c34605ae186d5cbe52d7aa..75f1cd14bea184934c2001ba604391b610bf7293 100644 (file)
                pinctrl-names = "default";
                pinctrl-0 = <&pinctrl_gpio_keys>;
 
-               volume-up {
+               key-volume-up {
                        label = "Volume Up";
                        gpios = <&gpio5 11 GPIO_ACTIVE_LOW>;
                        linux,code = <KEY_VOLUMEUP>;
                        wakeup-source;
                };
 
-               volume-down {
+               key-volume-down {
                        label = "Volume Down";
                        gpios = <&gpio5 10 GPIO_ACTIVE_LOW>;
                        linux,code = <KEY_VOLUMEDOWN>;
                };
        };
 
-       spi4 {
+       spi-4 {
                compatible = "spi-gpio";
                pinctrl-names = "default";
                pinctrl-0 = <&pinctrl_spi4>;
-               gpio-sck = <&gpio1 13 GPIO_ACTIVE_HIGH>;
-               gpio-mosi = <&gpio1 9 GPIO_ACTIVE_HIGH>;
+               sck-gpios = <&gpio1 13 GPIO_ACTIVE_HIGH>;
+               mosi-gpios = <&gpio1 9 GPIO_ACTIVE_HIGH>;
                cs-gpios = <&gpio1 12 GPIO_ACTIVE_LOW>;
                num-chipselects = <1>;
                #address-cells = <1>;
                };
        };
 
+       reg_sd1_vmmc: regulator-sd1-vmmc {
+               compatible = "regulator-fixed";
+               regulator-name = "VDD_SD1";
+               regulator-min-microvolt = <3300000>;
+               regulator-max-microvolt = <3300000>;
+               gpio = <&gpio5 2 GPIO_ACTIVE_HIGH>;
+               enable-active-high;
+               startup-delay-us = <200000>;
+               off-on-delay-us = <20000>;
+       };
+
        reg_usb_otg1_vbus: regulator-usb-otg1-vbus {
                compatible = "regulator-fixed";
                regulator-name = "usb_otg1_vbus";
                pinctrl-0 = <&pinctrl_tsc2046_pendown>;
                interrupt-parent = <&gpio2>;
                interrupts = <29 0>;
-               pendown-gpio = <&gpio2 29 GPIO_ACTIVE_HIGH>;
-               ti,x-min = /bits/ 16 <0>;
-               ti,x-max = /bits/ 16 <0>;
-               ti,y-min = /bits/ 16 <0>;
-               ti,y-max = /bits/ 16 <0>;
-               ti,pressure-max = /bits/ 16 <0>;
-               ti,x-plate-ohms = /bits/ 16 <400>;
+               pendown-gpio = <&gpio2 29 GPIO_ACTIVE_LOW>;
+               touchscreen-max-pressure = <255>;
                wakeup-source;
        };
 };
        pinctrl-0 = <&pinctrl_i2c1>;
        status = "okay";
 
-       pmic: pfuze3000@8 {
+       pmic: pmic@8 {
                compatible = "fsl,pfuze3000";
                reg = <0x08>;
 
 };
 
 &usdhc1 {
-       pinctrl-names = "default";
-       pinctrl-0 = <&pinctrl_usdhc1>;
+       pinctrl-names = "default", "state_100mhz", "state_200mhz";
+       pinctrl-0 = <&pinctrl_usdhc1>, <&pinctrl_usdhc1_gpio>;
+       pinctrl-1 = <&pinctrl_usdhc1_100mhz>, <&pinctrl_usdhc1_gpio>;
+       pinctrl-2 = <&pinctrl_usdhc1_200mhz>, <&pinctrl_usdhc1_gpio>;
        cd-gpios = <&gpio5 0 GPIO_ACTIVE_LOW>;
        wp-gpios = <&gpio5 1 GPIO_ACTIVE_HIGH>;
+       vmmc-supply = <&reg_sd1_vmmc>;
        wakeup-source;
        keep-power-in-suspend;
        status = "okay";
                        >;
                };
 
+               pinctrl_usdhc1_gpio: usdhc1_gpiogrp {
+                       fsl,pins = <
+                               MX7D_PAD_SD1_CD_B__GPIO5_IO0            0x59 /* CD */
+                               MX7D_PAD_SD1_WP__GPIO5_IO1              0x59 /* WP */
+                               MX7D_PAD_SD1_RESET_B__GPIO5_IO2         0x59 /* vmmc */
+                               MX7D_PAD_GPIO1_IO08__SD1_VSELECT        0x59 /* VSELECT */
+                       >;
+               };
+
                pinctrl_usdhc1: usdhc1grp {
                        fsl,pins = <
                                MX7D_PAD_SD1_CMD__SD1_CMD               0x59
                                MX7D_PAD_SD1_DATA1__SD1_DATA1           0x59
                                MX7D_PAD_SD1_DATA2__SD1_DATA2           0x59
                                MX7D_PAD_SD1_DATA3__SD1_DATA3           0x59
-                               MX7D_PAD_SD1_CD_B__GPIO5_IO0            0x59 /* CD */
-                               MX7D_PAD_SD1_WP__GPIO5_IO1              0x59 /* WP */
-                               MX7D_PAD_SD1_RESET_B__GPIO5_IO2         0x59 /* vmmc */
+                       >;
+               };
+
+               pinctrl_usdhc1_100mhz: usdhc1grp_100mhz {
+                       fsl,pins = <
+                               MX7D_PAD_SD1_CMD__SD1_CMD               0x5a
+                               MX7D_PAD_SD1_CLK__SD1_CLK               0x1a
+                               MX7D_PAD_SD1_DATA0__SD1_DATA0           0x5a
+                               MX7D_PAD_SD1_DATA1__SD1_DATA1           0x5a
+                               MX7D_PAD_SD1_DATA2__SD1_DATA2           0x5a
+                               MX7D_PAD_SD1_DATA3__SD1_DATA3           0x5a
+                       >;
+               };
+
+               pinctrl_usdhc1_200mhz: usdhc1grp_200mhz {
+                       fsl,pins = <
+                               MX7D_PAD_SD1_CMD__SD1_CMD               0x5b
+                               MX7D_PAD_SD1_CLK__SD1_CLK               0x1b
+                               MX7D_PAD_SD1_DATA0__SD1_DATA0           0x5b
+                               MX7D_PAD_SD1_DATA1__SD1_DATA1           0x5b
+                               MX7D_PAD_SD1_DATA2__SD1_DATA2           0x5b
+                               MX7D_PAD_SD1_DATA3__SD1_DATA3           0x5b
                        >;
                };
 
index cff2e6a87171ae4040f4ba2458014a4a0fb214a5..4fe23b51cd1bc165dfa51dd491745fbc50f1bab7 100644 (file)
@@ -267,7 +267,7 @@ int power_init_board(void)
        struct udevice *dev;
        int ret, dev_id, rev_id;
 
-       ret = pmic_get("pfuze3000@8", &dev);
+       ret = pmic_get("pmic@8", &dev);
        if (ret == -ENODEV)
                return 0;
        if (ret != 0)