[COMMON] mmc: dw_mmc: dw_mmc caps bug fix
authorJaeHun Jung <jh0801.jung@samsung.com>
Fri, 1 Jun 2018 05:57:40 +0000 (14:57 +0900)
committerJaehun Jung <jh0801.jung@samsung.com>
Wed, 20 Jun 2018 00:18:12 +0000 (09:18 +0900)
Change-Id: Ifaf38aca4b0585c33352db5262b2524571707233
Signed-off-by: JaeHun Jung <jh0801.jung@samsung.com>
drivers/mmc/host/dw_mmc.c

index de7b8bf3a3a6ba5bb09f3aff859d2c55cc4f71ba..7e7220391c9004512b7534367daa4801854f78b8 100644 (file)
@@ -3335,7 +3335,7 @@ static int dw_mci_init_slot_caps(struct dw_mci_slot *slot)
        int ctrl_id;
 
        if (host->pdata->caps)
-               mmc->caps = host->pdata->caps;
+               mmc->caps |= host->pdata->caps;
 
        /*
         * Support MMC_CAP_ERASE by default.
@@ -3344,7 +3344,7 @@ static int dw_mci_init_slot_caps(struct dw_mci_slot *slot)
        mmc->caps |= MMC_CAP_ERASE;
 
        if (host->pdata->pm_caps)
-               mmc->pm_caps = host->pdata->pm_caps;
+               mmc->pm_caps |= host->pdata->pm_caps;
 
        if (host->dev->of_node) {
                ctrl_id = of_alias_get_id(host->dev->of_node, "mshc");
@@ -3364,7 +3364,7 @@ static int dw_mci_init_slot_caps(struct dw_mci_slot *slot)
        }
 
        if (host->pdata->caps2)
-               mmc->caps2 = host->pdata->caps2;
+               mmc->caps2 |= host->pdata->caps2;
 
        /* Process SDIO IRQs through the sdio_irq_work. */
        if (mmc->caps & MMC_CAP_SDIO_IRQ)