]> err.no Git - linux-2.6/commitdiff
mmc: sdhci: fix voltage ocr
authorPierre Ossman <drzeus@drzeus.cx>
Fri, 2 Feb 2007 21:41:41 +0000 (22:41 +0100)
committerPierre Ossman <drzeus@drzeus.cx>
Sun, 4 Feb 2007 19:54:12 +0000 (20:54 +0100)
Some bad if-clauses caused the driver to just report the highest
supported voltage, not all.

Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
drivers/mmc/sdhci.c

index 24803538570a8b8d6537d89850d5c272a487ac65..4bf1fea5e2c405acccfa1b7ebbc069a2d323a787 100644 (file)
@@ -1291,9 +1291,9 @@ static int __devinit sdhci_probe_slot(struct pci_dev *pdev, int slot)
        mmc->ocr_avail = 0;
        if (caps & SDHCI_CAN_VDD_330)
                mmc->ocr_avail |= MMC_VDD_32_33|MMC_VDD_33_34;
-       else if (caps & SDHCI_CAN_VDD_300)
+       if (caps & SDHCI_CAN_VDD_300)
                mmc->ocr_avail |= MMC_VDD_29_30|MMC_VDD_30_31;
-       else if (caps & SDHCI_CAN_VDD_180)
+       if (caps & SDHCI_CAN_VDD_180)
                mmc->ocr_avail |= MMC_VDD_17_18|MMC_VDD_18_19;
 
        if ((host->max_clk > 25000000) && !(caps & SDHCI_CAN_DO_HISPD)) {