[PATCH 2/2] mmc: mmc_spi: enable Highspeed for above 25MHz

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Any setup supporting more than 25MHz is able to utilize
highspeed, so enable it even when not explicitly specified.

Signed-off-by: Christian Loehle <cloehle@xxxxxxxxxxxxxx>
---
 drivers/mmc/host/mmc_spi.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/mmc/host/mmc_spi.c b/drivers/mmc/host/mmc_spi.c
index 106dd204b1a7..0a74c2f55542 100644
--- a/drivers/mmc/host/mmc_spi.c
+++ b/drivers/mmc/host/mmc_spi.c
@@ -1378,6 +1378,9 @@ static int mmc_spi_probe(struct spi_device *spi)
 	mmc->f_min = 400000;
 	mmc->f_max = spi->max_speed_hz;
 
+	if (mmc->f_max > 25000000)
+		mmc->caps |= MMC_CAP_SD_HIGHSPEED | MMC_CAP_MMC_HIGHSPEED;
+
 	host = mmc_priv(mmc);
 	host->mmc = mmc;
 	host->spi = spi;
-- 
2.34.1
Hyperstone GmbH | Reichenaustr. 39a  | 78467 Konstanz
Managing Director: Dr. Jan Peter Berns.
Commercial register of local courts: Freiburg HRB381782




[Index of Archives]     [Linux Memonry Technology]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux