diff options
Diffstat (limited to 'drivers/mmc/host')
-rw-r--r-- | drivers/mmc/host/Kconfig | 2 | ||||
-rw-r--r-- | drivers/mmc/host/mmci.c | 2 | ||||
-rw-r--r-- | drivers/mmc/host/msm_sdcc.c | 5 | ||||
-rw-r--r-- | drivers/mmc/host/omap.c | 10 | ||||
-rw-r--r-- | drivers/mmc/host/omap_hsmmc.c | 8 | ||||
-rw-r--r-- | drivers/mmc/host/pxamci.c | 14 | ||||
-rw-r--r-- | drivers/mmc/host/s3cmci.c | 2 |
7 files changed, 21 insertions, 22 deletions
diff --git a/drivers/mmc/host/Kconfig b/drivers/mmc/host/Kconfig index 432ae8358c86..e04b751680d0 100644 --- a/drivers/mmc/host/Kconfig +++ b/drivers/mmc/host/Kconfig | |||
@@ -329,7 +329,7 @@ config MMC_SDRICOH_CS | |||
329 | 329 | ||
330 | config MMC_TMIO | 330 | config MMC_TMIO |
331 | tristate "Toshiba Mobile IO Controller (TMIO) MMC/SD function support" | 331 | tristate "Toshiba Mobile IO Controller (TMIO) MMC/SD function support" |
332 | depends on MFD_TMIO || MFD_ASIC3 | 332 | depends on MFD_TMIO || MFD_ASIC3 || SUPERH |
333 | help | 333 | help |
334 | This provides support for the SD/MMC cell found in TC6393XB, | 334 | This provides support for the SD/MMC cell found in TC6393XB, |
335 | T7L66XB and also HTC ASIC3 | 335 | T7L66XB and also HTC ASIC3 |
diff --git a/drivers/mmc/host/mmci.c b/drivers/mmc/host/mmci.c index 705a5894a6bb..90d168ad03b6 100644 --- a/drivers/mmc/host/mmci.c +++ b/drivers/mmc/host/mmci.c | |||
@@ -56,7 +56,7 @@ static void mmci_set_clkreg(struct mmci_host *host, unsigned int desired) | |||
56 | clk = 255; | 56 | clk = 255; |
57 | host->cclk = host->mclk / (2 * (clk + 1)); | 57 | host->cclk = host->mclk / (2 * (clk + 1)); |
58 | } | 58 | } |
59 | if (host->hw_designer == 0x80) | 59 | if (host->hw_designer == AMBA_VENDOR_ST) |
60 | clk |= MCI_FCEN; /* Bug fix in ST IP block */ | 60 | clk |= MCI_FCEN; /* Bug fix in ST IP block */ |
61 | clk |= MCI_CLK_ENABLE; | 61 | clk |= MCI_CLK_ENABLE; |
62 | /* This hasn't proven to be worthwhile */ | 62 | /* This hasn't proven to be worthwhile */ |
diff --git a/drivers/mmc/host/msm_sdcc.c b/drivers/mmc/host/msm_sdcc.c index dba4600bcdb4..b31946e0b4ca 100644 --- a/drivers/mmc/host/msm_sdcc.c +++ b/drivers/mmc/host/msm_sdcc.c | |||
@@ -38,10 +38,9 @@ | |||
38 | #include <asm/div64.h> | 38 | #include <asm/div64.h> |
39 | #include <asm/sizes.h> | 39 | #include <asm/sizes.h> |
40 | 40 | ||
41 | #include <asm/mach/mmc.h> | 41 | #include <mach/mmc.h> |
42 | #include <mach/msm_iomap.h> | 42 | #include <mach/msm_iomap.h> |
43 | #include <mach/dma.h> | 43 | #include <mach/dma.h> |
44 | #include <mach/htc_pwrsink.h> | ||
45 | 44 | ||
46 | #include "msm_sdcc.h" | 45 | #include "msm_sdcc.h" |
47 | 46 | ||
@@ -775,13 +774,11 @@ msmsdcc_set_ios(struct mmc_host *mmc, struct mmc_ios *ios) | |||
775 | 774 | ||
776 | switch (ios->power_mode) { | 775 | switch (ios->power_mode) { |
777 | case MMC_POWER_OFF: | 776 | case MMC_POWER_OFF: |
778 | htc_pwrsink_set(PWRSINK_SDCARD, 0); | ||
779 | break; | 777 | break; |
780 | case MMC_POWER_UP: | 778 | case MMC_POWER_UP: |
781 | pwr |= MCI_PWR_UP; | 779 | pwr |= MCI_PWR_UP; |
782 | break; | 780 | break; |
783 | case MMC_POWER_ON: | 781 | case MMC_POWER_ON: |
784 | htc_pwrsink_set(PWRSINK_SDCARD, 100); | ||
785 | pwr |= MCI_PWR_ON; | 782 | pwr |= MCI_PWR_ON; |
786 | break; | 783 | break; |
787 | } | 784 | } |
diff --git a/drivers/mmc/host/omap.c b/drivers/mmc/host/omap.c index b8fd7af1ceeb..5f970e253e50 100644 --- a/drivers/mmc/host/omap.c +++ b/drivers/mmc/host/omap.c | |||
@@ -30,12 +30,12 @@ | |||
30 | #include <asm/io.h> | 30 | #include <asm/io.h> |
31 | #include <asm/irq.h> | 31 | #include <asm/irq.h> |
32 | 32 | ||
33 | #include <mach/board.h> | 33 | #include <plat/board.h> |
34 | #include <mach/mmc.h> | 34 | #include <plat/mmc.h> |
35 | #include <mach/gpio.h> | 35 | #include <mach/gpio.h> |
36 | #include <mach/dma.h> | 36 | #include <plat/dma.h> |
37 | #include <mach/mux.h> | 37 | #include <plat/mux.h> |
38 | #include <mach/fpga.h> | 38 | #include <plat/fpga.h> |
39 | 39 | ||
40 | #define OMAP_MMC_REG_CMD 0x00 | 40 | #define OMAP_MMC_REG_CMD 0x00 |
41 | #define OMAP_MMC_REG_ARGL 0x04 | 41 | #define OMAP_MMC_REG_ARGL 0x04 |
diff --git a/drivers/mmc/host/omap_hsmmc.c b/drivers/mmc/host/omap_hsmmc.c index 0aecaaebef3d..4b2322518909 100644 --- a/drivers/mmc/host/omap_hsmmc.c +++ b/drivers/mmc/host/omap_hsmmc.c | |||
@@ -30,11 +30,11 @@ | |||
30 | #include <linux/mmc/core.h> | 30 | #include <linux/mmc/core.h> |
31 | #include <linux/io.h> | 31 | #include <linux/io.h> |
32 | #include <linux/semaphore.h> | 32 | #include <linux/semaphore.h> |
33 | #include <mach/dma.h> | 33 | #include <plat/dma.h> |
34 | #include <mach/hardware.h> | 34 | #include <mach/hardware.h> |
35 | #include <mach/board.h> | 35 | #include <plat/board.h> |
36 | #include <mach/mmc.h> | 36 | #include <plat/mmc.h> |
37 | #include <mach/cpu.h> | 37 | #include <plat/cpu.h> |
38 | 38 | ||
39 | /* OMAP HSMMC Host Controller Registers */ | 39 | /* OMAP HSMMC Host Controller Registers */ |
40 | #define OMAP_HSMMC_SYSCONFIG 0x0010 | 40 | #define OMAP_HSMMC_SYSCONFIG 0x0010 |
diff --git a/drivers/mmc/host/pxamci.c b/drivers/mmc/host/pxamci.c index b00d67319058..bb47ff465c04 100644 --- a/drivers/mmc/host/pxamci.c +++ b/drivers/mmc/host/pxamci.c | |||
@@ -43,6 +43,9 @@ | |||
43 | #define NR_SG 1 | 43 | #define NR_SG 1 |
44 | #define CLKRT_OFF (~0) | 44 | #define CLKRT_OFF (~0) |
45 | 45 | ||
46 | #define mmc_has_26MHz() (cpu_is_pxa300() || cpu_is_pxa310() \ | ||
47 | || cpu_is_pxa935()) | ||
48 | |||
46 | struct pxamci_host { | 49 | struct pxamci_host { |
47 | struct mmc_host *mmc; | 50 | struct mmc_host *mmc; |
48 | spinlock_t lock; | 51 | spinlock_t lock; |
@@ -457,7 +460,7 @@ static void pxamci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios) | |||
457 | clk_enable(host->clk); | 460 | clk_enable(host->clk); |
458 | 461 | ||
459 | if (ios->clock == 26000000) { | 462 | if (ios->clock == 26000000) { |
460 | /* to support 26MHz on pxa300/pxa310 */ | 463 | /* to support 26MHz */ |
461 | host->clkrt = 7; | 464 | host->clkrt = 7; |
462 | } else { | 465 | } else { |
463 | /* to handle (19.5MHz, 26MHz) */ | 466 | /* to handle (19.5MHz, 26MHz) */ |
@@ -608,8 +611,7 @@ static int pxamci_probe(struct platform_device *pdev) | |||
608 | * Calculate minimum clock rate, rounding up. | 611 | * Calculate minimum clock rate, rounding up. |
609 | */ | 612 | */ |
610 | mmc->f_min = (host->clkrate + 63) / 64; | 613 | mmc->f_min = (host->clkrate + 63) / 64; |
611 | mmc->f_max = (cpu_is_pxa300() || cpu_is_pxa310()) ? 26000000 | 614 | mmc->f_max = (mmc_has_26MHz()) ? 26000000 : host->clkrate; |
612 | : host->clkrate; | ||
613 | 615 | ||
614 | pxamci_init_ocr(host); | 616 | pxamci_init_ocr(host); |
615 | 617 | ||
@@ -618,7 +620,7 @@ static int pxamci_probe(struct platform_device *pdev) | |||
618 | if (!cpu_is_pxa25x()) { | 620 | if (!cpu_is_pxa25x()) { |
619 | mmc->caps |= MMC_CAP_4_BIT_DATA | MMC_CAP_SDIO_IRQ; | 621 | mmc->caps |= MMC_CAP_4_BIT_DATA | MMC_CAP_SDIO_IRQ; |
620 | host->cmdat |= CMDAT_SDIO_INT_EN; | 622 | host->cmdat |= CMDAT_SDIO_INT_EN; |
621 | if (cpu_is_pxa300() || cpu_is_pxa310()) | 623 | if (mmc_has_26MHz()) |
622 | mmc->caps |= MMC_CAP_MMC_HIGHSPEED | | 624 | mmc->caps |= MMC_CAP_MMC_HIGHSPEED | |
623 | MMC_CAP_SD_HIGHSPEED; | 625 | MMC_CAP_SD_HIGHSPEED; |
624 | } | 626 | } |
@@ -760,6 +762,8 @@ static int pxamci_remove(struct platform_device *pdev) | |||
760 | if (mmc) { | 762 | if (mmc) { |
761 | struct pxamci_host *host = mmc_priv(mmc); | 763 | struct pxamci_host *host = mmc_priv(mmc); |
762 | 764 | ||
765 | mmc_remove_host(mmc); | ||
766 | |||
763 | if (host->pdata) { | 767 | if (host->pdata) { |
764 | gpio_cd = host->pdata->gpio_card_detect; | 768 | gpio_cd = host->pdata->gpio_card_detect; |
765 | gpio_ro = host->pdata->gpio_card_ro; | 769 | gpio_ro = host->pdata->gpio_card_ro; |
@@ -779,8 +783,6 @@ static int pxamci_remove(struct platform_device *pdev) | |||
779 | if (host->pdata && host->pdata->exit) | 783 | if (host->pdata && host->pdata->exit) |
780 | host->pdata->exit(&pdev->dev, mmc); | 784 | host->pdata->exit(&pdev->dev, mmc); |
781 | 785 | ||
782 | mmc_remove_host(mmc); | ||
783 | |||
784 | pxamci_stop_clock(host); | 786 | pxamci_stop_clock(host); |
785 | writel(TXFIFO_WR_REQ|RXFIFO_RD_REQ|CLK_IS_OFF|STOP_CMD| | 787 | writel(TXFIFO_WR_REQ|RXFIFO_RD_REQ|CLK_IS_OFF|STOP_CMD| |
786 | END_CMD_RES|PRG_DONE|DATA_TRAN_DONE, | 788 | END_CMD_RES|PRG_DONE|DATA_TRAN_DONE, |
diff --git a/drivers/mmc/host/s3cmci.c b/drivers/mmc/host/s3cmci.c index 99b74a351020..941a4d35ef8d 100644 --- a/drivers/mmc/host/s3cmci.c +++ b/drivers/mmc/host/s3cmci.c | |||
@@ -1360,7 +1360,7 @@ static struct mmc_host_ops s3cmci_ops = { | |||
1360 | 1360 | ||
1361 | static struct s3c24xx_mci_pdata s3cmci_def_pdata = { | 1361 | static struct s3c24xx_mci_pdata s3cmci_def_pdata = { |
1362 | /* This is currently here to avoid a number of if (host->pdata) | 1362 | /* This is currently here to avoid a number of if (host->pdata) |
1363 | * checks. Any zero fields to ensure reaonable defaults are picked. */ | 1363 | * checks. Any zero fields to ensure reasonable defaults are picked. */ |
1364 | }; | 1364 | }; |
1365 | 1365 | ||
1366 | #ifdef CONFIG_CPU_FREQ | 1366 | #ifdef CONFIG_CPU_FREQ |