]> git.baikalelectronics.ru Git - kernel.git/commit
mmc: sdhci-esdhc-imx: Allow all supported prescaler values
authorBenoît Thébaudeau <benoit@wsystem.com>
Tue, 30 May 2017 09:14:10 +0000 (11:14 +0200)
committerUlf Hansson <ulf.hansson@linaro.org>
Tue, 20 Jun 2017 08:30:34 +0000 (10:30 +0200)
commitcd4809e8235e6d6600c10714bbd154e56c383a8e
treeeb152a6cec41a45396dd28161e6e8c249fe0d477
parent9b8f8b2b63634021754e69d0574a1954a573f888
mmc: sdhci-esdhc-imx: Allow all supported prescaler values

On i.MX, SYSCTL.SDCLKFS may always be set to 0 in order to make the SD
clock frequency prescaler divide by 1 in SDR mode, even with the eSDHC.
The previous minimum prescaler value of 2 in SDR mode with the eSDHC was
a code remnant from PowerPC, which actually has this limitation on
earlier revisions.

In DDR mode, the prescaler can divide by up to 512.

The maximum SD clock frequency in High Speed mode is 50 MHz. On i.MX25,
this change makes it possible to get 48 MHz from the USB PLL
(240 MHz / 5 / 1) instead of only 40 MHz from the USB PLL
(240 MHz / 3 / 2) or 33.25 MHz from the AHB clock (133 MHz / 2 / 2).

Signed-off-by: Benoît Thébaudeau <benoit@wsystem.com>
Acked-by: Adrian Hunter <adrian.hunter@intel.com>
Reviewed-by: Fabio Estevam <fabio.estevam@nxp.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/host/sdhci-esdhc-imx.c