mmc: sdhci: Use sdhci-caps-mask and sdhci-caps to change the caps read during __sdhci...
authorZach Brown <zach.brown@ni.com>
Wed, 2 Nov 2016 15:26:16 +0000 (10:26 -0500)
committerNitin Garg <nitin.garg@nxp.com>
Mon, 19 Mar 2018 20:36:49 +0000 (15:36 -0500)
commitfd293162b6f3f7d9822f75490d8629918d6a9a1b
tree40d03580186295975a39ae4ebacdb549ce313689
parentaa99f67910bafd7578dfd6bcec2db8a6d50cc4fc
mmc: sdhci: Use sdhci-caps-mask and sdhci-caps to change the caps read during __sdhci_read_caps

The sdhci capabilities register can be incorrect. The sdhci-caps-mask
and sdhci-caps dt properties specify which bits of the register are
incorrect and what their values should be. This patch makes the sdhci
driver use those properties to correct the caps during
__sdhci_read_caps.

During __sdhci_read_caps
Use the sdhci-caps-mask property to turn off the incorrect bits of the
sdhci register after reading them.
Use the sdhci-caps to turn on bits after using sdhci-caps-mask to turn
off the incorrect ones.

Signed-off-by: Zach Brown <zach.brown@ni.com>
Acked-by: Adrian Hunter <adrian.hunter@intel.com>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
(cherry picked from commit 92e0c44b92e463a47746b520ea9aa9ef154f27e7)
drivers/mmc/host/sdhci.c