[BUG] mx6cuboxi : broken MMC support

François Perrad francois.perrad at gadz.org
Sun Oct 11 10:07:50 CEST 2020


Le sam. 10 oct. 2020 à 21:18, Baruch Siach <baruch at tkos.co.il> a écrit :

> Hi François
>
> On Sat, Oct 10 2020, François Perrad wrote:
> > With 2020.07 (or 2020.04 or 2020.10), something goes wrong on this board.
> > I think it is related to
> >
> https://gitlab.denx.de/u-boot/u-boot/-/commit/6c3fbf3e456c49c2f43c0c286106a0d4b099b67b
> >
> > 2020.01 works fine with mmc0 (mmc0 is current device)
> > 2020.07 fails with mmc1
> > both versions are built in the Builroot environment,
> > and I use a Micro SD with the Cubox.
> >
> > Here, the working version 2020.01
> >
> > U-Boot SPL 2020.01 (Oct 09 2020 - 22:28:05 +0200)
> > Trying to boot from MMC1
> >
> >
> > U-Boot 2020.01 (Oct 09 2020 - 22:28:05 +0200)
> >
> > CPU:   Freescale i.MX6SOLO rev1.3 996 MHz (running at 792 MHz)
> > CPU:   Commercial temperature grade (0C to 95C) at 30C
> > Reset cause: POR
> > Board: MX6 Cubox-i
> > DRAM:  512 MiB
> > MMC:   FSL_SDHC: 0, FSL_SDHC: 1
> > Loading Environment from MMC... *** Warning - bad CRC, using default
> > environment
> >
> > No panel detected: default to HDMI
> > Display: HDMI (1024x768)
> > In:    serial
> > Out:   serial
> > Err:   serial
> > Net:   FEC
> > Hit any key to stop autoboot:  0
> > switch to partitions #0, OK
> > mmc0 is current device
> > Scanning mmc 0:1...
> > Found U-Boot script /boot/boot.scr
> > 336 bytes read in 106 ms (2.9 KiB/s)
> > ## Executing script at 12000000
> > 36612 bytes read in 121 ms (294.9 KiB/s)
> > 8552176 bytes read in 652 ms (12.5 MiB/s)
> > ## Flattened Device Tree blob at 18000000
> >    Booting using the fdt blob at 0x18000000
> >    Using Device Tree in place at 18000000, end 1800bf03
> >
> > Starting kernel ...
>
> The 'boot.scr' script here is board/solidrun/mx6cubox/boot.scr.txt from
> the Buildroot repo:
>
> setenv finduuid "part uuid mmc 0:1 uuid"
> run finduuid
> run findfdt
> setenv bootargs "console=ttymxc0,115200 root=PARTUUID=${uuid} rootwait
> rootfstype=ext4"
> load mmc 0:1 ${fdt_addr} boot/${fdtfile}
> load mmc 0:1 ${loadaddr} boot/zImage
> bootz ${loadaddr} - ${fdt_addr}
>
> Is that correct?
>

Yes, I use this script from Buildroot.


>
> > Now, with the version 2020.07
> >
> > U-Boot SPL 2020.07 (Oct 06 2020 - 13:33:44 +0200)
> > WDT:   Not found!
> > Trying to boot from MMC1
> >
> >
> > U-Boot 2020.07 (Oct 06 2020 - 13:33:44 +0200)
> >
> > CPU:   Freescale i.MX6SOLO rev1.3 996 MHz (running at 792 MHz)
> > CPU:   Commercial temperature grade (0C to 95C) at 36C
> > Reset cause: POR
> > Board: MX6 Cubox-i
> > DRAM:  512 MiB
> > MMC:   FSL_SDHC: 1, FSL_SDHC: 2
> > Loading Environment from MMC... *** Warning - bad CRC, using default
> > environment
> >
> > No panel detected: default to HDMI
> > Display: HDMI (1024x768)
> > In:    serial
> > Out:   serial
> > Err:   serial
> > Net:
> > Warning: ethernet at 2188000 using MAC address from ROM
> > eth0: ethernet at 2188000
> > Hit any key to stop autoboot:  0
> > switch to partitions #0, OK
> > mmc1 is current device
> > Scanning mmc 1:1...
>
> This might be the cause of the problem. The script listed above
> hardcodes "mmc 0:1". Changing that to "mmc 1:1" might fix this issue.
>
>
After changing the 3 occurrences of "mmc 0:1",the fdt file and kernel are
not correctly loaded.
(nothing happens after the message "Starting kernel ...")

Here the full log :

U-Boot SPL 2020.07 (Oct 11 2020 - 09:41:04 +0200)
WDT:   Not found!
Trying to boot from MMC1


U-Boot 2020.07 (Oct 11 2020 - 09:41:04 +0200)

CPU:   Freescale i.MX6SOLO rev1.3 996 MHz (running at 792 MHz)
CPU:   Commercial temperature grade (0C to 95C) at 38C
Reset cause: POR
Board: MX6 Cubox-i
DRAM:  512 MiB
MMC:   FSL_SDHC: 1, FSL_SDHC: 2
Loading Environment from MMC... *** Warning - bad CRC, using default
environment

No panel detected: default to HDMI
Display: HDMI (1024x768)
In:    serial
Out:   serial
Err:   serial
Net:
Warning: ethernet at 2188000 using MAC address from ROM
eth0: ethernet at 2188000
Hit any key to stop autoboot:  0
switch to partitions #0, OK
mmc1 is current device
Scanning mmc 1:1...
Found U-Boot script /boot/boot.scr
336 bytes read in 13 ms (24.4 KiB/s)
## Executing script at 12000000
8552176 bytes read in 427 ms (19.1 MiB/s)
ERROR: Did not find a cmdline Flattened Device Tree

Starting kernel ...


> baruch
>
> > Found U-Boot script /boot/boot.scr
> > 336 bytes read in 12 ms (27.3 KiB/s)
> > ## Executing script at 12000000
> > SCRIPT FAILED: continuing...
> > switch to partitions #0, OK
> > mmc2(part 0) is current device
> > ** No partition table - mmc 2 **
> > No SATA device found!
> > starting USB...
>
> --
>                                                      ~. .~   Tk Open
> Systems
> =}------------------------------------------------ooO--U--Ooo------------{=
>    - baruch at tkos.co.il - tel: +972.52.368.4656, http://www.tkos.co.il -
>


More information about the U-Boot mailing list