]> git.ipfire.org Git - people/ms/u-boot.git/blobdiff - drivers/mmc/arm_pl180_mmci.c
mmc: Remove ops from struct mmc and put in mmc_ops
[people/ms/u-boot.git] / drivers / mmc / arm_pl180_mmci.c
index 5a55fe73b7f6c8a840bdde2da8168e2db4452bfb..4490e9710b8d30be85169a4846d0acbd9a4bca42 100644 (file)
@@ -335,6 +335,12 @@ static void host_set_ios(struct mmc *dev)
        udelay(CLK_CHANGE_DELAY);
 }
 
+static const struct mmc_ops arm_pl180_mmci_ops = {
+       .send_cmd = host_request,
+       .set_ios = host_set_ios,
+       .init = mmc_host_reset,
+};
+
 /*
  * mmc_host_init - initialize the mmc controller.
  * Set initial clock and power for mmc slot.
@@ -360,11 +366,7 @@ int arm_pl180_mmci_init(struct pl180_mmc_host *host)
        sdi_u32 = readl(&host->base->mask0) & ~SDI_MASK0_MASK;
        writel(sdi_u32, &host->base->mask0);
        strncpy(dev->name, host->name, sizeof(dev->name));
-       dev->send_cmd = host_request;
-       dev->set_ios = host_set_ios;
-       dev->init = mmc_host_reset;
-       dev->getcd = NULL;
-       dev->getwp = NULL;
+       dev->ops = &arm_pl180_mmci_ops;
        dev->host_caps = host->caps;
        dev->voltages = host->voltages;
        dev->f_min = host->clock_min;