From: David Brownell Date: Wed, 31 Dec 2008 17:50:30 +0000 (-0800) Subject: mmc: warn about voltage mismatches X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=f6e10b865c3ea56bdaa8c6ecfee313b997900dbb;p=linux-beck.git mmc: warn about voltage mismatches Get rid of a silent failure mode when the MMC/SD host doesn't support the voltages needed to operate a given card, by adding a warning. A 3.3V host and a 3.0V card, for example, no longer need to mysteriously just not work at all. This isn't the best diagnostic; ideally it would also tell what voltage the card and host support (and not just by dumping the bitmasks). Signed-off-by: David Brownell Signed-off-by: Pierre Ossman --- diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c index 5f288aeeb721..df6ce4a06cf3 100644 --- a/drivers/mmc/core/core.c +++ b/drivers/mmc/core/core.c @@ -542,6 +542,8 @@ u32 mmc_select_voltage(struct mmc_host *host, u32 ocr) host->ios.vdd = bit; mmc_set_ios(host); } else { + pr_warning("%s: host doesn't support card's voltages\n", + mmc_hostname(host)); ocr = 0; }