|
@@ -883,10 +883,14 @@ static int mmc_init_card(struct mmc_host *host, u32 ocr,
|
|
|
card->ext_csd.generic_cmd6_time);
|
|
|
if (err && err != -EBADMSG)
|
|
|
goto free_card;
|
|
|
- }
|
|
|
|
|
|
- if (!err)
|
|
|
- card->poweroff_notify_state = MMC_POWERED_ON;
|
|
|
+ /*
|
|
|
+ * The err can be -EBADMSG or 0,
|
|
|
+ * so check for success and update the flag
|
|
|
+ */
|
|
|
+ if (!err)
|
|
|
+ card->poweroff_notify_state = MMC_POWERED_ON;
|
|
|
+ }
|
|
|
|
|
|
/*
|
|
|
* Activate high speed (if supported)
|