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 waiting for MMC root device on boot



Good afternoon TI community,

Thank you for all of your support so far in helping get our board up and running. I'm able to load SPL and u-boot from an SD card, and then begin loading the Linux kernel, but it hangs on the message "waiting for root device"

[ 1.726613] Waiting for root device PARTUUID=19b1aec4-02...

I've been reading through several of the existing posts and this seems to be related to an SD card detect problem. I'm able to successfully read from the SD card during u-boot because the bootloader doesn't use the SD card detect pin. I confirmed with a scope that the pin is high when unplugged, and pulled low when an SD card is inserted. At this stage, I would be ok disabling the SD card detect altogether but I haven't been able to do so successfully. 

How can I completely disable checking the SD card detect pin in order to get around this error? Are there any kernel changes required? Why is it not detecting the SD card detect pin pulled low? Here's the relevant source in my dts file.

Thanks in advance!

Chris

sd_mmc_pins: sd_mmc_pins {

pinctrl-single,pins = <
....

0x138 ( PIN_INPUT | MUX_MODE7 ) /* (N16) gmii1_rxd2.gpio2[19] (CDn)*/
>;
};

vmmc2: fixedregulator@0 {
compatible = "regulator-fixed";
regulator-name = "vmmc2";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-always-on;
};

&mmc2 {
pinctrl-names = "default";
pinctrl-0 = <&sd_mmc_pins>;
bus-width = <0x4>;
cd-gpios = <&gpio2 19 GPIO_ACTIVE_LOW>;
status = "okay";
vmmc-supply = <&vmmc2>;
/* ti,non-removable; */
/* broken-cd; */
};

  • The software team have been notified. They will respond here.
  • Hi Chris,

    Yes, disabling mmc_cd will require kernel changes.

    You can try hardcoding the output of map_hsmmc_card_detect() & omap_hsmmc_get_cd() functions in drivers/mmc/host/omap_hsmmc.c.
    Also again try hardcoding the related card detection functions (either cd or gpio_cd) from drivers/mmc/core/:
    mmc.c
    host.c
    sd.c
    slog-gpio.c

    Why is it not detecting the SD card detect pin pulled low?

    I suspect there might be something wrong with your device tree file. Could you please attach it? Also please attach the full console log.

    Best Regards,
    Yordan
  • Hi Yordan,

    This ended up being a problem with my device tree file. I had used the auto-generated copy from TI pinmux tool, but I noticed that they are defined slightly differently syntax for the MMC signals in some of the reference dts files. I changed PIN_INPUT to PIN_INPUT_PULLUP and it loaded Linux from the SD card. Perhaps the pinmux tool generated dts file for an older copy of Linux source.

    Best,

    Chris