BBB U-boot Verification eMMC

Source: Internet
Author: User

Goal:

Refer to the "COMMON/CMD_MMC.C" lookup eMMC code, after the MMC bus initialization function, traverse the MMC bus, find eMMC and

Print EMMC information.


Add our traversal function to the last side of the Mmc_initialize function in "DRIVERS/MMC/MMC.C"

Int mmc_initialize (bd_t *bis)
{
     init_list_head (&mmc_devices);
     cur_dev_num = 0;
     if (Board_mmc_init (bis) < 0)
          cpu_mmc_init (bis);

     print_mmc_devices (', ');

     printf ("---------------------------------------------\ n");
     my_print_mmcinfo (0);                          ,         &NB Sp    //printing devices on mmc0
     printf ("---------------------------------------------\ n");
     my_print_mmcinfo (1);                          ,         &NB Sp    //printing devices on MMC1
     printf ("---------------------------------------------\ n");
     return 0;
}


static void My_print_mmcinfo (int index)
{
struct MMC *mmc;
MMC = find_mmc_device (index);
if (MMC)
{
Mmc_init (MMC);
Print_mmcinfo (MMC); Simply glue this function in the CMD_MMC.C.
}
Else
{
printf ("No MMC device at slot%d\n", index);
}
}


The print results are as follows: This printout was made under FTP-initiated conditions.

---------------------------------------------
Card did not respond to voltage select!
Device:omap SD/MMC
Manufacturer id:0
oem:0
Name:tran speed:0
Rd Block len:0
MMC version 0.0
High Capacity:no
capacity:0 Bytes
Bus Width:1-bit
---------------------------------------------
Mmc_send_cmd:timeout:No status update
Device:omap SD/MMC
Manufacturer Id:70
oem:100
Name:mmc04
Tran speed:52000000
Rd Block len:512
MMC version 4.0
High Capacity:yes
capacity:3.6 GiB
Bus Width:4-bit
---------------------------------------------


From the print results you can see that eMMC is hanging under MMC1, MMC0 is the SD card

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.