We have a product using Verdin iMX8M-Plus 1.0D.
We want to have internal pull ups at ports GPIO_SODIMM_30 which is GPIO3_IO25 and GPIO_SODIMM_32 which is GPIO3_IO22.
Therefore I modified dts file as below:
/*
GPIO control bits: PE HYS PUE ODE FSEL X DSE1 DSE0 X
-----------------
Pull Select Field : PE_0_PULL_DISABLE / PE_1_PULL_ENABLE
Input Select Field : HYS_0_CMOS / HYS_1_SCHMITT
Pull Up / Down Config. : PUE_0_WEAK_PULL_DOWN / PUE_1_WEAK_PULL_UP
Open Drain Field : ODE_0_OPEN_DRAIN_DISABLE / ODE_1_OPEN_DRAIN_ENABLE
Slew Rate Field : FSEL_0_SLOW_SLEW_RATE / FSEL_1_FAST_SLEW_RATE
Drive Strength Field : DSE_X1 / DSE_X2 / DSE_X4 /DSE_X6
-----------------
Example: 0b010010110 -> 0x096 (PE_0_PULL_DISABLE | HYS_1_SCHMITT | PUE_0_WEAK_PULL_DOWN | ODE_0_OPEN_DRAIN_DISABLE | FSEL_1_FAST_SLEW_RATE | DSE_X6)
Example: 0b111110110 -> 0x1F6 (PE_1_PULL_ENABLE | HYS_1_SCHMITT | PUE_1_WEAK_PULL_UP | ODE_1_OPEN_DRAIN_ENABLE | FSEL_1_FAST_SLEW_RATE | DSE_X6)
*/
&iomuxc {
pinctrl-0 = <&pinctrl_additionalgpio>;
pinctrl_additionalgpio: additionalgpios {
fsl,pins = <
MX8MP_IOMUXC_SAI5_RXD1__GPIO3_IO22 0x140 /* SODIMM 32 - PWR_2_VALID with PU */
MX8MP_IOMUXC_SAI5_MCLK__GPIO3_IO25 0x140 /* SODIMM 30 - PWR_1_VALID with PU */
...
...
>;
};
};
But I can not observe any pullup on the SODIMM pins 30 and 32 when they are inputs. When I assemble external pullup, below command returns 1 and 0 as expected. But once I remove external pullups, I always get zero.
root@verdin-imx8mp-06976886:~# gpioget 2 22
0
root@verdin-imx8mp-06976886:~# gpioget 2 25
0
root@verdin-imx8mp-06976886:~# cat /sys/kernel/debug/gpio
gpiochip0: GPIOs 0-31, parent: platform/30200000.gpio, 30200000.gpio:
gpio-0 ( )
gpiochip1: GPIOs 32-63, parent: platform/30210000.gpio, 30210000.gpio:
gpio-32 ( )
gpio-42 ( |id ) in hi IRQ
gpio-43 ( |regulator-wifi-en ) out hi
gpio-44 ( |cd ) in hi IRQ ACTIVE LOW
gpio-52 ( |regulator-module-eth) out hi
gpio-61 ( |CTRL_SLEEP_MOCI# ) out hi
gpiochip2: GPIOs 64-95, parent: platform/30220000.gpio, 30220000.gpio:
gpio-64 ( )
gpio-83 ( |led_status_1 ) out lo
gpio-84 ( |led_red ) out lo
gpio-90 ( |scl ) out lo
gpio-91 ( |sda ) in lo
gpiochip3: GPIOs 96-127, parent: platform/30230000.gpio, 30230000.gpio:
gpio-96 ( |Wake-Up ) in hi IRQ ACTIVE LOW
gpio-98 ( |led_status_2 ) out lo
gpio-115 ( |reset ) out hi ACTIVE LOW
gpio-118 ( |regulator-usdhc2 ) out lo
gpio-121 ( |led_green ) out lo
gpiochip4: GPIOs 128-159, parent: platform/30240000.gpio, 30240000.gpio:
gpio-128 ( )
gpio-137 ( |spi_imx ) out hi
gpio-142 ( |scl ) out lo
gpio-143 ( |sda ) in lo
gpio-144 ( |scl ) out lo
gpio-145 ( |sda ) in lo
gpio-148 ( |scl ) out lo
gpio-149 ( |sda ) in lo
No actually I didn’t touch any toradex specific dtsi file. But of course we included that file in our custom dst file. None of the SAI modules are enabled, all have status = "disabled". Still shall we remove them? What is the proper way of removing those pins without touching imx8mp-verdin.dtsi file?
I added following lines into root of our custom dst file, it is compiled, I put it into the device, reboot but still no pull ups.
Could you please share the entire device tree that you created? So we can have a deeper look into it.
Have you tried with another carrier board? Did you see the same problem?