@@ -1147,6 +1147,15 @@ static void mmci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
}
}
+ /*
+ * If clock = 0 and the block needs a certain value in the clreg
+ * to function, we need to gate the clock by removing MCI_PWR_ON.
+ * This is a special case for ST Micro variants, since the power
+ * register in the ARM legacy case is used for powering the cards.
+ */
+ if (!ios->clock && variant->clkreg)
+ pwr &= ~MCI_PWR_ON;
+
spin_lock_irqsave(&host->lock, flags);
mmci_set_clkreg(host, ios->clock);