diff options
author | Philip Rakity <prakity@marvell.com> | 2010-11-07 16:22:28 -0500 |
---|---|---|
committer | Chris Ball <cjb@laptop.org> | 2010-11-07 16:45:08 -0500 |
commit | 25d5c699f983a2da51f5165eb9a8fc6338124b6c (patch) | |
tree | 2da310eee6d3673e14ad5c0fa7e2a6667ebbff49 /drivers | |
parent | 151f52f09c5728ecfdd0c289da1a4b30bb416f2c (diff) |
mmc: Fix printing of card DDR type
We should not call mmc_card_set_ddr_mode() if we are in single data
mode. This sets DDR and causes the kernel log to say the card is DDR
when it is not.
Explicitly set ddr to 0 rather then rely on MMC_SDR_MODE being 0 when
doing the checks.
Signed-off-by: Philip Rakity <prakity@marvell.com>
Acked-by: Linus Walleij <linus.walleij@stericsson.com>
Acked-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: Chris Ball <cjb@laptop.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/mmc/core/mmc.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/mmc/core/mmc.c b/drivers/mmc/core/mmc.c index 995261f7fd70..77f93c3b8808 100644 --- a/drivers/mmc/core/mmc.c +++ b/drivers/mmc/core/mmc.c | |||
@@ -375,7 +375,7 @@ static int mmc_init_card(struct mmc_host *host, u32 ocr, | |||
375 | struct mmc_card *oldcard) | 375 | struct mmc_card *oldcard) |
376 | { | 376 | { |
377 | struct mmc_card *card; | 377 | struct mmc_card *card; |
378 | int err, ddr = MMC_SDR_MODE; | 378 | int err, ddr = 0; |
379 | u32 cid[4]; | 379 | u32 cid[4]; |
380 | unsigned int max_dtr; | 380 | unsigned int max_dtr; |
381 | 381 | ||
@@ -562,7 +562,11 @@ static int mmc_init_card(struct mmc_host *host, u32 ocr, | |||
562 | 1 << bus_width, ddr); | 562 | 1 << bus_width, ddr); |
563 | err = 0; | 563 | err = 0; |
564 | } else { | 564 | } else { |
565 | mmc_card_set_ddr_mode(card); | 565 | if (ddr) |
566 | mmc_card_set_ddr_mode(card); | ||
567 | else | ||
568 | ddr = MMC_SDR_MODE; | ||
569 | |||
566 | mmc_set_bus_width_ddr(card->host, bus_width, ddr); | 570 | mmc_set_bus_width_ddr(card->host, bus_width, ddr); |
567 | } | 571 | } |
568 | } | 572 | } |