i.MX8QXP hangs in SPL after a "reboot" command

Hi,
Does anyone managed to successfully run a "reboot" command on i.MX8QXP with a mainline kernel? I see a hang in SPL on a imx8qxp-mek board:
# reboot # Stopping network: OK Saving random seed: [ 6.305029] random: dd: uninitialized urandom read (512 bytes read) OK Stopping klogd: OK Stopping syslogd: OK umount: devtmpfs busy - remounted read-only [ 6.352820] EXT4-fs (mmcblk1p2): re-mounted. Opts: (null) The system is going down NOW! Sent SIGTERM to all processes Se[ 8.362121] kvm: exiting hardware virtualization [ 8.397849] reboot: Restarting system
U-Boot SPL 2020.04-rc4-00061-ge0718b3ab7 (Apr 02 2020 - 16:14:22 -0300) Normal Boot WDT: Not found! Trying to boot from MMC2_2 spl: mmc init failed with error: -70 SPL: failed to boot from all boot devices ### ERROR ### Please RESET the board ###
Any suggestions?
Thanks,
Fabio Estevam

On Thu, Apr 2, 2020 at 4:21 PM Fabio Estevam festevam@gmail.com wrote:
U-Boot SPL 2020.04-rc4-00061-ge0718b3ab7 (Apr 02 2020 - 16:14:22 -0300) Normal Boot WDT: Not found! Trying to boot from MMC2_2 spl: mmc init failed with error: -70 SPL: failed to boot from all boot devices ### ERROR ### Please RESET the board ###
I added the following debug line:
--- a/drivers/mmc/fsl_esdhc_imx.c +++ b/drivers/mmc/fsl_esdhc_imx.c @@ -499,6 +499,7 @@ static int esdhc_send_cmd_common(struct fsl_esdhc_priv *priv, struct mmc *mmc, irqstat = esdhc_read32(®s->irqstat);
if (irqstat & CMD_ERR) { + printf("****** -ECOMM comming from 1\n"); err = -ECOMM; goto out; }
And this is what I got after issuing a 'reboot' command in Linux:
# reboot # Stopping network: OK Saving random seed: [ 5.255229] random: dd: uninitialized urandom read (512 bytes read) OK Stopping klogd: OK Stopping syslogd: OK umount: devtmpfs busy - remounted read-only [ 5.309631] EXT4-fs (mmcblk1p2): re-mounted. Opts: (null) The system is going down NOW! Sent SIGTERM to all processes Sen[ 7.318988] kvm: exiting hardware virtualization [ 7.339445] reboot: Restarting system
U-Boot SPL 2020.04-rc4-00062-g1e193557d5-dirty (Apr 04 2020 - 10:14:43 -0300) Normal Boot WDT: Not found! Trying to boot from MMC2_2 ****** -ECOMM comming from 1 ****** -ECOMM comming from 1 spl: mmc init failed with error: -70 SPL: failed to boot from all boot devices ### ERROR ### Please RESET the board ###
Any ideas as to why CMD_ERR bit is being set in the irqstat register?
Thanks

Subject: Re: i.MX8QXP hangs in SPL after a "reboot" command
On Thu, Apr 2, 2020 at 4:21 PM Fabio Estevam festevam@gmail.com wrote:
U-Boot SPL 2020.04-rc4-00061-ge0718b3ab7 (Apr 02 2020 - 16:14:22 -0300) Normal Boot WDT: Not found! Trying to boot from MMC2_2 spl: mmc init failed with error: -70 SPL: failed to boot from all boot devices ### ERROR ### Please RESET the board ###
Do you enable M4 partition in your image?
Regards, Peng.
I added the following debug line:
--- a/drivers/mmc/fsl_esdhc_imx.c +++ b/drivers/mmc/fsl_esdhc_imx.c @@ -499,6 +499,7 @@ static int esdhc_send_cmd_common(struct fsl_esdhc_priv *priv, struct mmc *mmc, irqstat = esdhc_read32(®s->irqstat);
if (irqstat & CMD_ERR) {
printf("****** -ECOMM comming from 1\n"); err = -ECOMM; goto out; }
And this is what I got after issuing a 'reboot' command in Linux:
# reboot # Stopping network: OK Saving random seed: [ 5.255229] random: dd: uninitialized urandom read (512 bytes read) OK Stopping klogd: OK Stopping syslogd: OK umount: devtmpfs busy - remounted read-only [ 5.309631] EXT4-fs (mmcblk1p2): re-mounted. Opts: (null) The system is going down NOW! Sent SIGTERM to all processes Sen[ 7.318988] kvm: exiting hardware virtualization [ 7.339445] reboot: Restarting system
U-Boot SPL 2020.04-rc4-00062-g1e193557d5-dirty (Apr 04 2020 - 10:14:43 -0300) Normal Boot WDT: Not found! Trying to boot from MMC2_2 ****** -ECOMM comming from 1 ****** -ECOMM comming from 1 spl: mmc init failed with error: -70 SPL: failed to boot from all boot devices ### ERROR ### Please RESET the board ###
Any ideas as to why CMD_ERR bit is being set in the irqstat register?
Thanks

Hi Peng,
On Tue, Apr 7, 2020 at 9:47 PM Peng Fan peng.fan@nxp.com wrote:
Subject: Re: i.MX8QXP hangs in SPL after a "reboot" command
On Thu, Apr 2, 2020 at 4:21 PM Fabio Estevam festevam@gmail.com wrote:
U-Boot SPL 2020.04-rc4-00061-ge0718b3ab7 (Apr 02 2020 - 16:14:22 -0300) Normal Boot WDT: Not found! Trying to boot from MMC2_2 spl: mmc init failed with error: -70 SPL: failed to boot from all boot devices ### ERROR ### Please RESET the board ###
Do you enable M4 partition in your image?
I haven't done anything with regards to the M4 partition.
What should I do exactly?
Thanks

Subject: Re: i.MX8QXP hangs in SPL after a "reboot" command
Hi Peng,
On Tue, Apr 7, 2020 at 9:47 PM Peng Fan peng.fan@nxp.com wrote:
Subject: Re: i.MX8QXP hangs in SPL after a "reboot" command
On Thu, Apr 2, 2020 at 4:21 PM Fabio Estevam festevam@gmail.com wrote:
U-Boot SPL 2020.04-rc4-00061-ge0718b3ab7 (Apr 02 2020 - 16:14:22 -0300) Normal Boot WDT: Not found! Trying to boot from MMC2_2 spl: mmc init failed with error: -70 SPL: failed to boot from all boot devices ### ERROR ### Please RESET the board ###
Do you enable M4 partition in your image?
I haven't done anything with regards to the M4 partition.
What should I do exactly?
Ok, then I think you not have M4 used. Which kernel are you using? Which SCFW/SECO?
Regards, Peng.
Thanks

Hi Peng,
On Tue, Apr 7, 2020 at 11:06 PM Peng Fan peng.fan@nxp.com wrote:
Ok, then I think you not have M4 used.
What needs to be done in order to use the M4?
Which kernel are you using? Which SCFW/SECO?
I am using kernel 5.6.2.
SCFW is imx-sc-firmware-1.2.7.1 SECO is imx-seco-2.3.1
If I use the NXP U-Boot from the imx_4.19.35_1.1.0 BSP the reboot works fine.
Any suggestions?
Thanks
participants (2)
-
Fabio Estevam
-
Peng Fan