aboutsummaryrefslogtreecommitdiff
path: root/drivers/mmc
diff options
context:
space:
mode:
authorMarek Vasut <marek.vasut+renesas@gmail.com>2017-09-23 13:01:20 +0200
committerMarek Vasut <marek.vasut+renesas@gmail.com>2018-04-11 23:11:59 +0200
commit58c35b17aa8f6192d44edcd016ab2f7045bc0e97 (patch)
treebf081f5105c1fdf882e09a2451e61c4dce149e32 /drivers/mmc
parenta7b7401c786871ec65572e1cd66703a0eb461060 (diff)
downloadu-boot-58c35b17aa8f6192d44edcd016ab2f7045bc0e97.zip
u-boot-58c35b17aa8f6192d44edcd016ab2f7045bc0e97.tar.gz
u-boot-58c35b17aa8f6192d44edcd016ab2f7045bc0e97.tar.bz2
mmc: matsushita-common: Always check controller version
Handle the controller version even if quirks are set. The controller in Renesas Gen3 SoCs does provide the version register, which indicates a controller v10 and the controller does support internal DMA and /1024 divider. Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com> Cc: Jaehoon Chung <jh80.chung@samsung.com> Cc: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'drivers/mmc')
-rw-r--r--drivers/mmc/matsushita-common.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/drivers/mmc/matsushita-common.c b/drivers/mmc/matsushita-common.c
index 377f349..d5facd9 100644
--- a/drivers/mmc/matsushita-common.c
+++ b/drivers/mmc/matsushita-common.c
@@ -722,16 +722,15 @@ int matsu_sd_probe(struct udevice *dev, u32 quirks)
plat->cfg.name = dev->name;
plat->cfg.host_caps |= MMC_MODE_HS_52MHz | MMC_MODE_HS;
- if (quirks) {
+ if (quirks)
priv->caps = quirks;
- } else {
- priv->version = matsu_sd_readl(priv, MATSU_SD_VERSION) &
- MATSU_SD_VERSION_IP;
- dev_dbg(dev, "version %x\n", priv->version);
- if (priv->version >= 0x10) {
- priv->caps |= MATSU_SD_CAP_DMA_INTERNAL;
- priv->caps |= MATSU_SD_CAP_DIV1024;
- }
+
+ priv->version = matsu_sd_readl(priv, MATSU_SD_VERSION) &
+ MATSU_SD_VERSION_IP;
+ dev_dbg(dev, "version %x\n", priv->version);
+ if (priv->version >= 0x10) {
+ priv->caps |= MATSU_SD_CAP_DMA_INTERNAL;
+ priv->caps |= MATSU_SD_CAP_DIV1024;
}
if (fdt_get_property(gd->fdt_blob, dev_of_offset(dev), "non-removable",