mmc: sdhci-of-at91: Support external regulators
authorRomain Izard <romain.izard.pro@gmail.com>
Thu, 9 Mar 2017 15:18:20 +0000 (16:18 +0100)
committerUlf Hansson <ulf.hansson@linaro.org>
Thu, 16 Mar 2017 14:24:28 +0000 (15:24 +0100)
commit2ce0c7b65505e0d915e99389cced45b478dc935d
tree223dc5e190c84ccf0e6876595713b06f4c0295f7
parent8bcd37d8b21de13d068414c018c9599281294a01
mmc: sdhci-of-at91: Support external regulators

The SDHCI controller in the SAMA5D2 chip requires a valid voltage set
in the power control register, otherwise commands will fail with a
timeout error.

When using the regulator framework to specify the regulator used by the
mmc device, the voltage is not configured, and it is not possible to use
the connected device.

Implement a custom 'set_power' function for this specific hardware, that
configures the voltage in the register in all cases.

Signed-off-by: Romain Izard <romain.izard.pro@gmail.com>
Acked-by: Ludovic Desroches <ludovic.desroches@microchip.com>
Cc: stable@vger.kernel.org #4.9+
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/host/sdhci-of-at91.c