aboutsummaryrefslogtreecommitdiff
path: root/drivers/mmc
diff options
context:
space:
mode:
authorBen Dooks <ben-linux@fluff.org>2008-11-03 20:18:58 +0000
committerBen Dooks <ben-linux@fluff.org>2008-11-03 20:30:49 +0000
commit439c45acfde46ab914099a25bf0559567904f632 (patch)
tree88081a181cea3499623f2c516c672f36d0376194 /drivers/mmc
parent20d21005881376e8f1e3525c80ee63b735adf0ab (diff)
SDHCI: Add set_ios hook
Add a set_ios hook which is called when the SDHCI driver is called to change parameters such as clock or card width. Signed-off-by: Ben Dooks <ben-linux@fluff.org>
Diffstat (limited to 'drivers/mmc')
-rw-r--r--drivers/mmc/host/sdhci.c3
-rw-r--r--drivers/mmc/host/sdhci.h3
2 files changed, 6 insertions, 0 deletions
diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c
index 17a1ca18a59..2827ccd9f35 100644
--- a/drivers/mmc/host/sdhci.c
+++ b/drivers/mmc/host/sdhci.c
@@ -1038,6 +1038,9 @@ static void sdhci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
sdhci_init(host);
}
+ if (host->ops->set_ios)
+ host->ops->set_ios(host, ios);
+
sdhci_set_clock(host, ios->clock);
if (ios->power_mode == MMC_POWER_OFF)
diff --git a/drivers/mmc/host/sdhci.h b/drivers/mmc/host/sdhci.h
index fb3931c88a3..9fbf0ddf241 100644
--- a/drivers/mmc/host/sdhci.h
+++ b/drivers/mmc/host/sdhci.h
@@ -269,6 +269,9 @@ struct sdhci_ops {
int (*enable_dma)(struct sdhci_host *host);
unsigned int (*get_max_clock)(struct sdhci_host *host);
unsigned int (*get_timeout_clock)(struct sdhci_host *host);
+
+ void (*set_ios)(struct sdhci_host *host,
+ struct mmc_ios *ios);
};