]> git.sur5r.net Git - u-boot/blobdiff - drivers/mmc/arm_pl180_mmci.c
mmc: arm_pl180_mmci: update arm_pl180_mmci_init() prototype
[u-boot] / drivers / mmc / arm_pl180_mmci.c
index ddf8383f1c63163781205dd342108ac2af65a7ee..7898b0dd70f40d28d177075a7c6472a9aa632b8f 100644 (file)
@@ -348,9 +348,8 @@ static const struct mmc_ops arm_pl180_mmci_ops = {
  * Set initial clock and power for mmc slot.
  * Initialize mmc struct and register with mmc framework.
  */
-int arm_pl180_mmci_init(struct pl180_mmc_host *host)
+int arm_pl180_mmci_init(struct pl180_mmc_host *host, struct mmc **mmc)
 {
-       struct mmc *mmc;
        u32 sdi_u32;
 
        writel(host->pwr_init, &host->base->power);
@@ -373,11 +372,12 @@ int arm_pl180_mmci_init(struct pl180_mmc_host *host)
        else
                host->cfg.b_max = CONFIG_SYS_MMC_MAX_BLK_COUNT;
 
-       mmc = mmc_create(&host->cfg, host);
-       if (mmc == NULL)
+       *mmc = mmc_create(&host->cfg, host);
+       if (!*mmc)
                return -1;
 
-       debug("registered mmc interface number is:%d\n", mmc->block_dev.devnum);
+       debug("registered mmc interface number is:%d\n",
+             (*mmc)->block_dev.devnum);
 
        return 0;
 }