we have used Colibri i.MX7D 1GB (eMMC) in a custom-designed product many times.
Since I tried BSP 5.6.0 I experience a strange behaviour of GPIO15 (pin 178 of SODIMM):
pin is fully controllable as output via u-boot from serial console
pin goes high when kernel boots, then goes low a few seconds after “root login” appears on serial console
if I try to control pin from my application or by using “old sysfs method”, I see it assigned to the correct driver, set as output and being “hi”/“lo” in /sys/kernel/debug/gpio, but no change in hardware status. If set it as an input and apply a voltage, I see the value changing in /sys/kernel/debug/gpio.
doing the same with GPIO14 (pin 188) works without issues from user space/application
older BSP (with 5.4.91 kernel, I think it was BSP 5.4.x) works perfectly
I tried with both custom device tree and Toradex eval-v3 device tree, same issue
I tried with both custom kernel and Toradex Minimal Image 5.6.0 from Tezi, same issue
HW: Colibri iMX7D 1GB V1.1A on custom carrier board or Viola Carrier Board
SW: BSP 5.6.0
install a custom-built image based on BSP 5.6.0 build 18 minimal
put an old precompiled Kernel form BSP 5.4 ( Linux colibri-imx7-emmc-06949105 5.4.129-5.4.0-devel+git.cb88cc157bfb ) with its modules into bootfs/rootfs of the module (zImage in /boot and modules in /lib/modules)
and it works.
I’ve tested our downstream minimal image on the BSP 5.6.0 and I was indeed able to check the behavior you presented here. However, I think the problem is more linked to which kernel version you’re using. I’ve been able to control the GPIO 15 normally using the BSP 5.6.0 Upstream Kernel.
The version I used was:
TDX Wayland with XWayland Upstream 5.6.0+build.18 (dunfell)
Can you please test with this version? Would this be a plausible solution for you at the moment? I forwarded this point to our team to see how we could deal with this so that customers willing to use Downstream Kernel are able to use this GPIO pin if needed.
just finished adjusting my Yocto build to work with upstream kernel.
Without running repo sync, it compiled upstream kernel 5.4.161+gitAUTOINC+ed9c66090d-r0 (downstream was also 5.4.161) and GPIO works fine.
We’ll test other peripherals and performance and hope to find them OK.
I’ll keep you updated on the status of the Downstream Kernel.
How are you trying to use gpio-poweroff so that I can try to reproduce it on my side? By the way, did you check our article post about it? GPIO (Linux) | Toradex Developer Center. There is a mention to enabling CONFIG_POWER_RESET_GPIO. Did you check if the upstream kernel has this enabled?