},
};
-#define to_tx51_esdhc_cfg(p) container_of(p, struct tx51_esdhc_cfg, cfg)
+static inline struct tx51_esdhc_cfg *to_tx51_esdhc_cfg(struct fsl_esdhc_cfg *cfg)
+{
+ return container_of(cfg, struct tx51_esdhc_cfg, cfg);
+}
int board_mmc_getcd(struct mmc *mmc)
{
cfg->num_pads);
cfg->cfg.sdhc_clk = mxc_get_clock(MXC_ESDHC_CLK);
- fsl_esdhc_initialize(bis, &cfg->cfg);
-
ret = gpio_request_one(cfg->cd_gpio,
GPIOF_INPUT, "MMC CD");
if (ret) {
continue;
}
+ debug("%s: Initializing MMC slot %d\n", __func__, i);
+ fsl_esdhc_initialize(bis, &cfg->cfg);
+
mmc = find_mmc_device(i);
if (mmc == NULL)
continue;