Skip to content

Commit

Permalink
mmc: core: Fix setting power notify state variable for non-eMMC
Browse files Browse the repository at this point in the history
This patch skips the setting of the power notify state variable
for non eMMC 4.5 devices. Also fixes the problem of omap_hsmmc
noisy/broken for suspend resume reported by Kevin Hilman.

Signed-off-by: Girish K S <girish.shivananjappa@linaro.org>
Acked-by: Ulf Hansson <ulf.hansson@stericsson.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
  • Loading branch information
Girish K S authored and Chris Ball committed Dec 10, 2011
1 parent 6de5fc9 commit 96a85d5
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions drivers/mmc/core/mmc.c
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down

0 comments on commit 96a85d5

Please sign in to comment.