aboutsummaryrefslogtreecommitdiff
path: root/drivers/mmc
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mmc')
-rw-r--r--drivers/mmc/mmc-uclass.c13
-rw-r--r--drivers/mmc/mmc.c6
2 files changed, 19 insertions, 0 deletions
diff --git a/drivers/mmc/mmc-uclass.c b/drivers/mmc/mmc-uclass.c
index 5dda20cda5e..9c6a8ba4760 100644
--- a/drivers/mmc/mmc-uclass.c
+++ b/drivers/mmc/mmc-uclass.c
@@ -51,6 +51,19 @@ int mmc_set_ios(struct mmc *mmc)
return dm_mmc_set_ios(mmc->dev);
}
+void dm_mmc_send_init_stream(struct udevice *dev)
+{
+ struct dm_mmc_ops *ops = mmc_get_ops(dev);
+
+ if (ops->send_init_stream)
+ ops->send_init_stream(dev);
+}
+
+void mmc_send_init_stream(struct mmc *mmc)
+{
+ dm_mmc_send_init_stream(mmc->dev);
+}
+
int dm_mmc_get_wp(struct udevice *dev)
{
struct dm_mmc_ops *ops = mmc_get_ops(dev);
diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c
index 24b5e16a3bf..1875b31ad1f 100644
--- a/drivers/mmc/mmc.c
+++ b/drivers/mmc/mmc.c
@@ -1198,6 +1198,10 @@ static inline int bus_width(uint cap)
}
#if !CONFIG_IS_ENABLED(DM_MMC)
+static void mmc_send_init_stream(struct mmc *mmc)
+{
+}
+
static int mmc_set_ios(struct mmc *mmc)
{
int ret = 0;
@@ -1983,6 +1987,8 @@ int mmc_start_init(struct mmc *mmc)
mmc_set_bus_width(mmc, 1);
mmc_set_clock(mmc, 1);
+ mmc_send_init_stream(mmc);
+
/* Reset the Card */
err = mmc_go_idle(mmc);