Hi,
I found that the HS200 and HS400 of the eMMC were not enabled when running the u-boot mode. The bus speed is only set to 52MHz. How can I enable the HS200 and HS400?
Regards,
Simon
Hi Simon
eMMC operating mode is selected automatically by reading Extended CSD register.
What uboot version used in the case, is it possible to provide full log.
Recommended to try uboot from source.codeaurora.org/external/imx/linux-imx repository
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hi Igor,
Thanks for your reply.
Below is the log during the bootup and the info of eMMC on the MCIMX8M-EVK. By default, it is running High Speed mode at 52MHz.
I enabled the MMC_HS400_ES, MMC_HS400 and MMC_HS200 in the u-boot .config file. But the u-boot only running the HS200 mode.
Then I traced the uboot code. When I looked into the function static int mmc_get_capabilities(struct mmc *mmc), I found that the HS400 and HS400_ES were not enabled in the mmc->card_caps.
I can hardcode the HS400 and HS400_ES support in the mmc->card_caps. But what is the proper way to enable it?
Regards,
Simon
U-Boot 2018.03 (Jun 26 2020 - 09:41:41 +0800)
CPU: Freescale i.MX8MQ rev2.1 1500 MHz (running at 1000 MHz)
CPU: Commercial temperature grade (0C to 95C) at 46C
Reset cause: POR
Model: Freescale i.MX8MQ EVK
DRAM: 3 GiB
MMC: FSL_SDHC: 0, FSL_SDHC: 1
Loading Environment from MMC... *** Warning - bad CRC, using default environment
Failed (-5)
No panel detected: default to HDMI
Display: HDMI (1280x720)
cdn_api_checkalive: keep-alive counter did not increment for 10us...
HDMI enable failed!
In: serial
Out: serial
Err: serial
BuildInfo:
- ATF
- U-Boot 2018.03
switch to partitions #0, OK
mmc0(part 0) is current device
Detect USB boot. Will enter fastboot mode!
Net:
Warning: ethernet@30be0000 using MAC address from ROM
eth0: ethernet@30be0000
Fastboot: Normal
Boot from USB for mfgtools
Use default environment for mfgtools
Run bootcmd_mfg: run mfgtool_args;if iminfo ${initrd_addr}; then if test ${tee} = yes; then bootm ${tee_addr} ${initrd_addr} ${fdt_addr}; else booti ${loadaddr} ${initrd_addr} ${fdt_addr}; fi; else echo "Run fastboot ..."; fastboot 0; fi;
Hit any key to stop autoboot: 0
## Checking Image at 43800000 ...
Unknown image format!
Run fastboot ...
u-boot=> mmc info
Device: FSL_SDHC
Manufacturer ID: 45
OEM: 100
Name: DG401
Bus Speed: 52000000
Mode : MMC DDR52 (52MHz)
Rd Block Len: 512
MMC version 5.1
High Capacity: Yes
Capacity: 14.7 GiB
Bus Width: 8-bit DDR
Erase Group Size: 512 KiB
HC WP Group Size: 8 MiB
User Capacity: 14.7 GiB WRREL
Boot Capacity: 4 MiB ENH
RPMB Capacity: 4 MiB ENH
u-boot=>
Hi Simon
does that emmc support HS400 mode? One can try to debug it in fsl_esdhc.c
(search for HS400) :
fsl_esdhc.c\mmc\drivers - uboot-imx - i.MX U-Boot
Best regards
igor
Hi Igor,
Yes, the eMMC on the MCIMX8M-EVK can support HS400_ES. I tried to decode the byte 196 of the EXT_CSD which is the DEVICE_TYPE from the eMMC chip. It indicates that this device can support the HS400 and HS400_ES.
Can you suggest which part i should modify in the fsl_esdhc.c?
Regards,
Simon
Hi Simon
please pay attention to fsl_esdhc_probe() function and value of fsl,strobe-dll-delay-target
as it depends on the board layout and the emmc chip you use. Different cases may require
different values and may be needed to try several vaules.
fsl_esdhc.c\mmc\drivers - uboot-imx - i.MX U-Boot
One can check data_strobe line with oscilloscope, as for HS400 mode emmc use
the data_strobe line to give the command and data for read operation.
Best regards
igor