Hello *,
I have an IMX53 with an MMC THGBM4G4D1HBAIR, but seems that linux can't read the Card ID.
The Layout
The MMC_RST and MMC_CMD are connected on PATA_IORDY and NPATA_RESET_B respectivelly.
In my board code have:
// IOMUX MMC
MX53_PAD_PATA_DATA8__ESDHC3_DAT0,
MX53_PAD_PATA_DATA9__ESDHC3_DAT1,
MX53_PAD_PATA_DATA10__ESDHC3_DAT2,
MX53_PAD_PATA_DATA11__ESDHC3_DAT3,
MX53_PAD_PATA_DATA0__ESDHC3_DAT4,
MX53_PAD_PATA_DATA1__ESDHC3_DAT5,
MX53_PAD_PATA_DATA2__ESDHC3_DAT6,
MX53_PAD_PATA_DATA3__ESDHC3_DAT7,
MX53_PAD_PATA_IORDY__ESDHC3_CLK,
MX53_PAD_PATA_RESET_B__ESDHC3_CMD,
MX53_PAD_PATA_DA_0__ESDHC3_RST,
static struct mxc_mmc_platform_data mmc3_data = {
.ocr_mask = MMC_VDD_31_32,
.caps = MMC_CAP_NONREMOVABLE | MMC_CAP_8_BIT_DATA | MMC_CAP_DATA_DDR,
.min_clk = 400000,
.max_clk = 50000000,
.card_fixed = 1,
.card_inserted_state = 0,
.clock_mmc = "esdhc_clk",
.power_mmc = NULL,
};
mxc_register_device(&mxc_iim_device, &iim_data);
//mxc_register_device(&mxc_pwm2_device, NULL);
mxc_register_device(&mxcsdhc1_device, &mmc1_data); // SDCARD this work good
mxc_register_device(&mxcsdhc3_device, &mmc3_data); // MMC not work
mxc_register_device(&mxc_ssi1_device, NULL);
mxc_register_device(&mxc_ssi2_device, NULL); //
The kernel log oututp with MMC debug enabled say:
Jan 2 00:25:19 nsip user.warn kernel: .
Jan 2 00:25:19 nsip user.debug kernel: mmc1: starting CMD2 arg 00000000 flags 00000067
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_send_command()]: sdhci_send_command 0x2 is starting...
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_send_command()]: Complete sending cmd, transfer mode would be 0x2090000.
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_irq()]: *** mmc1 got interrupt: 0x00010001
Jan 2 00:25:19 nsip user.debug kernel: mmc1: req failed (CMD2): -110, retrying...
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_send_command()]: sdhci_send_command 0x2 is starting...
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_send_command()]: Complete sending cmd, transfer mode would be 0x2090000.
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_irq()]: *** mmc1 got interrupt: 0x00010001
Jan 2 00:25:19 nsip user.debug kernel: mmc1: req failed (CMD2): -110, retrying...
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_send_command()]: sdhci_send_command 0x2 is starting...
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_send_command()]: Complete sending cmd, transfer mode would be 0x2090000.
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_irq()]: *** mmc1 got interrupt: 0x00010001
Jan 2 00:25:19 nsip user.debug kernel: mmc1: req failed (CMD2): -110, retrying...
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_send_command()]: sdhci_send_command 0x2 is starting...
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_send_command()]: Complete sending cmd, transfer mode would be 0x2090000.
Jan 2 00:25:19 nsip user.debug kernel: mxsdhci [sdhci_irq()]: *** mmc1 got interrupt: 0x00010001
Jan 2 00:25:19 nsip user.debug kernel: mmc1: req done (CMD2): -110: 00000000 00000000 00000000 00000000
Seems that the function mmc_all_send_cid fail for timeout (err -110).
Any Idea?
Solved! Go to Solution.
Hi Cristian
had you set SION bit for mmc pad iomux settings ?
One can try to test mmc signals with oscilloscope using simple OBDS
mmc_test.c (read mmc ID)
On-Board Diagnostic Suit for the i.MX53 Quick Start Board
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------
Hello Igorpaykov,
thank's for reply.
The iomux settings:
was not call, so I simply don't apply this settings (as your indication).
Really thank's for your suggestion!!
Hi Cristian
had you set SION bit for mmc pad iomux settings ?
One can try to test mmc signals with oscilloscope using simple OBDS
mmc_test.c (read mmc ID)
On-Board Diagnostic Suit for the i.MX53 Quick Start Board
Best regards
igor
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------