This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

AM335x eMMC1 boot issue

Other Parts Discussed in Thread: CSD

Hello TI,

Customer's AM335x board refer to BBK reference design, Board info is:

1.SD Card in MMC0

2.8G Byte Toushiba emmc in MMC1, Support emmc 5.1,(THGBMHG6C1BAIL)

3.512M Byte DDR3 memory

4.Can boot from SD card.

I  amend linux driver mmc.c to support emmc5.1, Because the error back for ext_csd.rev is 8, so I changed (card->ext_csd.rev > 6) to(card->ext_csd.rev > 8) .

After that, Customer's board can read emmc1 info, Can sfdisk emmc1.

if (card->ext_csd.rev > 8) {
pr_err("%s: unrecognised EXT_CSD revision %d\n",
mmc_hostname(card->host), card->ext_csd.rev);
err = -EINVAL;
goto out;
}

wpi@ubuntu:~$ /home/wpi/ti-sdk-am335x-evm-06.00.00.00/board-support/linux-3.2.0-psp04.06.00.11/drivers/mmc/core/mmc.c

Print info:

[ 2.056518] mmcblk1: mmc1:0001 008G30 7.28 GiB 
[ 2.061676] mmcblk1boot0: mmc1:0001 008G30 partition 1 4.00 MiB
[ 2.068481] mmcblk1boot1: mmc1:0001 008G30 partition 2 4.00 MiB
[ 2.077819] mmcblk1: p1 p2 p3 p4
[ 2.088195] mmcblk1boot1: unknown partition table
[ 2.097473] mmcblk1boot0: unknown partition table
[ 2.129730] kjournald starting. Commit interval 5 seconds
[ 2.135742] EXT3-fs (mmcblk0p2): recovery complete
[ 2.215667] EXT3-fs (mmcblk0p2): mounted filesystem with ordered data mode
[ 2.223114] VFS: Mounted root (ext3 filesystem) readonly on device 179:2.
[ 2.231323] Freeing init memory: 236K

I changed uboot for boot from emmc1:

changed nandboot to mmcboot,changed mmc0 to mmc1,Please help check if my change is right or not.

#define CONFIG_EXTRA_ENV_SETTINGS \
"loadaddr=0x80200000\0" \
"kloadaddr=0x80007fc0\0" \
"fdtaddr=0x80F80000\0" \
"fdt_high=0xffffffff\0" \
"rdaddr=0x81000000\0" \
"bootfile=uImage\0" \
"fdtfile=\0" \
"console=ttyO0,115200n8\0" \
"optargs=\0" \
"mtdids=" MTDIDS_DEFAULT "\0" \
"mtdparts=" MTDPARTS_DEFAULT "\0" \
"dfu_alt_info_mmc=" DFU_ALT_INFO_MMC "\0" \
"dfu_alt_info_emmc=rawemmc mmc 1 3751936\0" \
"dfu_alt_info_nand=" DFU_ALT_INFO_NAND "\0" \
"mmcdev=1\0" \
"mmcroot=/dev/mmcblk1p2 ro\0" \
"mmcrootfstype=ext3 rootwait\0" \

........

#define CONFIG_BOOTCOMMAND \
"mmc dev ${mmcdev}; if mmc rescan; then " \
"echo SD/MMC found on device ${mmcdev};" \
"if run loadbootenv; then " \
"echo Loaded environment from ${bootenv};" \
"run importbootenv;" \
"fi;" \
"if test -n $uenvcmd; then " \
"echo Running uenvcmd ...;" \
"run uenvcmd;" \
"fi;" \
"if run loaduimagefat; then " \
"run mmcboot;" \
"elif run loaduimage; then " \
"run mmcboot;" \
"else " \
"echo Could not find ${bootfile} ;" \
"fi;" \
"else " \
"run mmcboot;" \
"fi;" \

Now the board can boot from emmc , MLO,U-boot,Kernel all can run in emmc1,But Stop at:

[    1.938446] Waiting for root device /dev/mmcblk1p2...

I searched www.deyisupport.com & http://e2e.ti.com ,Read all of this question BBS posts, Can not solve this bug,Please help,Thanks a lot!

1.My filesystem can not run?

2.U-boot / Kernel need amended?

I'm WPI TI DFAE,Local in Nanjing Jiangsu China, This bug I debug for customer in past two week, Customer need solve this bug soon,Please help ,Thanks!

My email is :eric.cai@wpi-group.com