Colibri iMX6 not powering off even with "poweroff -f"

Hi, I’m having some troubles to poweroff the board. Some times the board remains ON even after the “poweroff -f” was applied.
The dmesg says:
eboot: Power down
[ 221.571915] reboot: Power down
[ 221.575018] machine_power_off pm_power_off() did return

Does anyone have this error? How could I fix this, because the application where I use this is Battery Supplied.

Note: application based on (2.8b3) prior to the the last one

Thansk in advance.

Hi @darkanoid

Could you provide the version of the Hardware and Software (Bsp.) of your module?
Which carrier board are you using?

Have you done any changes to the Software (Kernel, devicetree)? If yes, could you share the changes?

Does anyone have this error? How could I fix this, because the application where I use this is Battery Supplied.

We are not aware of this error.

Note: application based on (2.8b3) prior to the the last one

Could you update to Bsp 2.8b5 and try again if you still see the issue?

Best regards,
Jaski

Hi @jaski.tx,

HW: Col iMX6DL 512MB IT V1.1A

Carrier: I’m using a custom carrier based on Viola plus

Kernel: Only change the initial image

Devicetree: added can0 channel functionality according to High performance, low power Embedded Computing Systems | Toradex Developer Center

commit 376063c6394aceaf306067d2a9cedd643e0db7dd
Author: Alejandro Clerici <ale.clerici@gmail.com>
Date:   Thu Nov 1 07:34:57 2018 -0700

    agregamos CAN driver

diff --git a/arch/arm/boot/dts/imx6dl-colibri-eval-v3.dts b/arch/arm/boot/dts/imx6dl-colibri-eval-v3.dts
index 85f88dc..58f3d11 100644
--- a/arch/arm/boot/dts/imx6dl-colibri-eval-v3.dts
+++ b/arch/arm/boot/dts/imx6dl-colibri-eval-v3.dts
@@ -97,6 +97,10 @@
        };
 };
 
+&can1 {
+       status = "okay";
+};
+
 /* Colibri SPI */
 &ecspi4 {
        status = "okay";
@@ -170,7 +174,6 @@
                &pinctrl_weim_gpio_5 &pinctrl_weim_gpio_6
                &pinctrl_csi_gpio_1
                &pinctrl_gpio_1
-               &pinctrl_gpio_2
                &pinctrl_usbh_oc_1 &pinctrl_usbc_id_1
        >;

Hi @darkanoid

We tried to reproduce the issue with your changes in Bsp 2.8b5 and we could manage to power off the module.

The dmesg says: eboot: Power down
[ 221.571915] reboot: Power down
[ 221.575018] machine_power_off pm_power_off() did return

how do you know that the module is not powered off?

About your dmseg, in my case when the module is well power off, I’ve only the message

reboot: Power down

the other message appear only when the board is not powered off ( machine_power_off pm_power_off() did return )

how do you know that the module is not powered off?

Because the power source remains with a current like when is ON.

I’m using a pin from the module to sustain the power on in the board.
The procedure to apply power to the module is (attached schematic). The other part of the board is the same as Viola / Apalis and all the powerup sequence has been checked

  1. Press the on button (SW_ON-OFF)-> applies power supply the voltage Reg and then to the module in the rigth order. The system starts.
  2. When the uboot starts, put a pin high (the memory that sustain the system on) GPIO_0 (PIN_75 SODIM)
  3. To poweroff, from the app I use the system(“poweroff -f”). And the pin that uboot puts high on the boot process should be off automatically and power off the entire board.

Attached is the schematic:

Hi
Thanks for the schematic.

And the pin that uboot puts high on the boot process should be off automatically and power off the entire board.

Is your application turning this pin off? Did you define this pins somewhere in a devicetree to be turned off?

best regards,
Jaski

Hi @jaski.tx,
Could you see the last message I’ve upload?

By now I’m using the system(“sync”) before down the control power pin. I’m not using “poweroff” nor “poweroff -f”
Is this enough or has problems with file corruption?

Hi @jaski.tx

Is your application turning this pin off? Did you define this pins somewhere in a devicetree to be turned off?

No, I’ve supossed that with the poweroff command, this pin goes down automatically. Is this wrong?

If yes, where I have to turnoff this pin?

hi @darkanoid

No, I’ve supossed that with the poweroff command, this pin goes down automatically. Is this wrong?

No, this pin does not go down automatically. You need to trigger it off. Please check also this for further Information.

Best regards,
Jaski

OK @jaski.tx
I’ll try it. Thanks!

You are welcome. Let us know your results.

Hi @jaski.tx
Well, I can’t get the proper configuration.
https://www.toradex.com/community/questions/35777/enabling-poweroff-pin.html?childToView=35875#comment-35875

Is there any problem in poweroff the system in this way?

  • system(“sync”)
  • turning off the power source (low the power pin)

Thanks in advance

While it is, of course, much cleaner to do a proper shutdown, you may also just cut the power with or even without doing a sync beforehand. This is also what we do test extensively in our validation & verification tests in our temperature chambers across the full rang of rated ambient temperatures.