From mboxrd@z Thu Jan 1 00:00:00 1970 From: mpa@pengutronix.de (Markus Pargmann) Date: Fri, 25 Apr 2014 14:38:20 +0200 Subject: [PATCH 21/38] mmc: sdhci: hack up driver to make it more compliant with UHS-1 In-Reply-To: References: <20140423185534.GA26756@n2100.arm.linux.org.uk> Message-ID: <20140425123820.GA15179@pengutronix.de> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Hi, On Wed, Apr 23, 2014 at 08:07:57PM +0100, Russell King wrote: > Patch suggested by Dong Aisheng , this avoids > additional clock start/stop cycles during the transition to 1.8V > signalling mode. > > Signed-off-by: Russell King I tested the series on imx6s with a RIoT board. With this patch applied the RIoT board emmc does not work. Here is the output of the board: # dmesg | grep mmc2 mmc2: no vqmmc regulator found mmc2: no vmmc regulator found mmc2: SDHCI controller on 219c000.usdhc [219c000.usdhc] using ADMA mmc2: BKOPS_EN bit is not set mmc2: Timeout waiting for hardware interrupt. mmc2: Timeout waiting for hardware interrupt. mmc2: Timeout waiting for hardware interrupt. mmc2: Timeout waiting for hardware interrupt. mmc2: error -110 whilst initialising MMC card mmc2: BKOPS_EN bit is not set mmc2: Timeout waiting for hardware interrupt. mmc2: Timeout waiting for hardware interrupt. mmc2: Timeout waiting for hardware interrupt. mmc2: Timeout waiting for hardware interrupt. mmc2: error -110 whilst initialising MMC card mmc2: BKOPS_EN bit is not set Any ideas? Regards, Markus > --- > drivers/mmc/host/sdhci.c | 12 ------------ > 1 file changed, 12 deletions(-) > > diff --git a/drivers/mmc/host/sdhci.c b/drivers/mmc/host/sdhci.c > index 748333ba6e96..0bcef2d42da4 100644 > --- a/drivers/mmc/host/sdhci.c > +++ b/drivers/mmc/host/sdhci.c > @@ -1507,12 +1507,6 @@ static void sdhci_do_set_ios(struct sdhci_host *host, struct mmc_ios *ios) > host->ops->set_clock(host, host->clock); > } > > - > - /* Reset SD Clock Enable */ > - clk = sdhci_readw(host, SDHCI_CLOCK_CONTROL); > - clk &= ~SDHCI_CLOCK_CARD_EN; > - sdhci_writew(host, clk, SDHCI_CLOCK_CONTROL); > - > if (host->ops->set_uhs_signaling) > host->ops->set_uhs_signaling(host, ios->timing); > else { > @@ -1546,9 +1540,6 @@ static void sdhci_do_set_ios(struct sdhci_host *host, struct mmc_ios *ios) > ios->drv_type = (preset & SDHCI_PRESET_DRV_MASK) > >> SDHCI_PRESET_DRV_SHIFT; > } > - > - /* Re-enable SD Clock */ > - host->ops->set_clock(host, host->clock); > } else > sdhci_writeb(host, ctrl, SDHCI_HOST_CONTROL); > > @@ -1757,9 +1748,6 @@ static int sdhci_do_start_signal_voltage_switch(struct sdhci_host *host, > ctrl |= SDHCI_CTRL_VDD_180; > sdhci_writew(host, ctrl, SDHCI_HOST_CONTROL2); > > - /* Wait for 5ms */ > - usleep_range(5000, 5500); > - > /* 1.8V regulator output should be stable within 5 ms */ > ctrl = sdhci_readw(host, SDHCI_HOST_CONTROL2); > if (ctrl & SDHCI_CTRL_VDD_180) > -- > 1.8.3.1 > > > _______________________________________________ > linux-arm-kernel mailing list > linux-arm-kernel at lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-arm-kernel > -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 836 bytes Desc: Digital signature URL: