summaryrefslogtreecommitdiff
path: root/drivers/mmc/mmc.c
diff options
context:
space:
mode:
authorPeng Fan <peng.fan@nxp.com>2018-03-05 16:20:40 +0800
committerYe Li <ye.li@nxp.com>2018-04-27 02:21:21 -0700
commita5bb0b38e6be1b8b8f92d11cccd3f7220f11ef74 (patch)
treea4814b52d2b48a3fa61fdab162a6d4be9e2e22c7 /drivers/mmc/mmc.c
parentbb628be4e993e98fb2fe8fc6af7b16e706d0f32d (diff)
MLK-18148 mmc: fix return value check condition
sd_read_ssr returns 0, means no error. Fixes: 5b2e72f32721484("mmc: read ssr only if MMC write support is enabled") Signed-off-by: Peng Fan <peng.fan@nxp.com> Cc: Jaehoon Chung <jh80.chung@samsung.com> Cc: Jean-Jacques Hiblot <jjhiblot@ti.com>
Diffstat (limited to 'drivers/mmc/mmc.c')
-rw-r--r--drivers/mmc/mmc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c
index c930893300..92ea78b8af 100644
--- a/drivers/mmc/mmc.c
+++ b/drivers/mmc/mmc.c
@@ -1689,7 +1689,7 @@ static int sd_select_mode_and_width(struct mmc *mmc, uint card_caps)
#if CONFIG_IS_ENABLED(MMC_WRITE)
err = sd_read_ssr(mmc);
- if (!err)
+ if (err)
pr_warn("unable to read ssr\n");
#endif
if (!err)