diff options
Diffstat (limited to 'arch/arm/mach-ux500/board-mop500-sdi.c')
-rw-r--r-- | arch/arm/mach-ux500/board-mop500-sdi.c | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/arch/arm/mach-ux500/board-mop500-sdi.c b/arch/arm/mach-ux500/board-mop500-sdi.c index 7f2cb6c5e2c1..6db0740128de 100644 --- a/arch/arm/mach-ux500/board-mop500-sdi.c +++ b/arch/arm/mach-ux500/board-mop500-sdi.c | |||
@@ -31,35 +31,6 @@ | |||
31 | * SDI 0 (MicroSD slot) | 31 | * SDI 0 (MicroSD slot) |
32 | */ | 32 | */ |
33 | 33 | ||
34 | /* GPIO pins used by the sdi0 level shifter */ | ||
35 | static int sdi0_en = -1; | ||
36 | static int sdi0_vsel = -1; | ||
37 | |||
38 | static int mop500_sdi0_ios_handler(struct device *dev, struct mmc_ios *ios) | ||
39 | { | ||
40 | switch (ios->power_mode) { | ||
41 | case MMC_POWER_UP: | ||
42 | case MMC_POWER_ON: | ||
43 | /* | ||
44 | * Level shifter voltage should depend on vdd to when deciding | ||
45 | * on either 1.8V or 2.9V. Once the decision has been made the | ||
46 | * level shifter must be disabled and re-enabled with a changed | ||
47 | * select signal in order to switch the voltage. Since there is | ||
48 | * no framework support yet for indicating 1.8V in vdd, use the | ||
49 | * default 2.9V. | ||
50 | */ | ||
51 | gpio_direction_output(sdi0_vsel, 0); | ||
52 | gpio_direction_output(sdi0_en, 1); | ||
53 | break; | ||
54 | case MMC_POWER_OFF: | ||
55 | gpio_direction_output(sdi0_vsel, 0); | ||
56 | gpio_direction_output(sdi0_en, 0); | ||
57 | break; | ||
58 | } | ||
59 | |||
60 | return 0; | ||
61 | } | ||
62 | |||
63 | #ifdef CONFIG_STE_DMA40 | 34 | #ifdef CONFIG_STE_DMA40 |
64 | struct stedma40_chan_cfg mop500_sdi0_dma_cfg_rx = { | 35 | struct stedma40_chan_cfg mop500_sdi0_dma_cfg_rx = { |
65 | .mode = STEDMA40_MODE_LOGICAL, | 36 | .mode = STEDMA40_MODE_LOGICAL, |
@@ -100,22 +71,6 @@ struct mmci_platform_data mop500_sdi0_data = { | |||
100 | 71 | ||
101 | static void sdi0_configure(struct device *parent) | 72 | static void sdi0_configure(struct device *parent) |
102 | { | 73 | { |
103 | int ret; | ||
104 | |||
105 | ret = gpio_request(sdi0_en, "level shifter enable"); | ||
106 | if (!ret) | ||
107 | ret = gpio_request(sdi0_vsel, | ||
108 | "level shifter 1v8-3v select"); | ||
109 | |||
110 | if (ret) { | ||
111 | pr_warning("unable to config sdi0 gpios for level shifter.\n"); | ||
112 | return; | ||
113 | } | ||
114 | |||
115 | /* Select the default 2.9V and enable level shifter */ | ||
116 | gpio_direction_output(sdi0_vsel, 0); | ||
117 | gpio_direction_output(sdi0_en, 1); | ||
118 | |||
119 | /* Add the device, force v2 to subrevision 1 */ | 74 | /* Add the device, force v2 to subrevision 1 */ |
120 | db8500_add_sdi0(parent, &mop500_sdi0_data, U8500_SDI_V2_PERIPHID); | 75 | db8500_add_sdi0(parent, &mop500_sdi0_data, U8500_SDI_V2_PERIPHID); |
121 | } | 76 | } |
@@ -123,8 +78,6 @@ static void sdi0_configure(struct device *parent) | |||
123 | void mop500_sdi_tc35892_init(struct device *parent) | 78 | void mop500_sdi_tc35892_init(struct device *parent) |
124 | { | 79 | { |
125 | mop500_sdi0_data.gpio_cd = GPIO_SDMMC_CD; | 80 | mop500_sdi0_data.gpio_cd = GPIO_SDMMC_CD; |
126 | sdi0_en = GPIO_SDMMC_EN; | ||
127 | sdi0_vsel = GPIO_SDMMC_1V8_3V_SEL; | ||
128 | sdi0_configure(parent); | 81 | sdi0_configure(parent); |
129 | } | 82 | } |
130 | 83 | ||
@@ -263,8 +216,6 @@ void __init snowball_sdi_init(struct device *parent) | |||
263 | /* External Micro SD slot */ | 216 | /* External Micro SD slot */ |
264 | mop500_sdi0_data.gpio_cd = SNOWBALL_SDMMC_CD_GPIO; | 217 | mop500_sdi0_data.gpio_cd = SNOWBALL_SDMMC_CD_GPIO; |
265 | mop500_sdi0_data.cd_invert = true; | 218 | mop500_sdi0_data.cd_invert = true; |
266 | sdi0_en = SNOWBALL_SDMMC_EN_GPIO; | ||
267 | sdi0_vsel = SNOWBALL_SDMMC_1V8_3V_GPIO; | ||
268 | sdi0_configure(parent); | 219 | sdi0_configure(parent); |
269 | } | 220 | } |
270 | 221 | ||
@@ -276,8 +227,6 @@ void __init hrefv60_sdi_init(struct device *parent) | |||
276 | db8500_add_sdi4(parent, &mop500_sdi4_data, U8500_SDI_V2_PERIPHID); | 227 | db8500_add_sdi4(parent, &mop500_sdi4_data, U8500_SDI_V2_PERIPHID); |
277 | /* External Micro SD slot */ | 228 | /* External Micro SD slot */ |
278 | mop500_sdi0_data.gpio_cd = HREFV60_SDMMC_CD_GPIO; | 229 | mop500_sdi0_data.gpio_cd = HREFV60_SDMMC_CD_GPIO; |
279 | sdi0_en = HREFV60_SDMMC_EN_GPIO; | ||
280 | sdi0_vsel = HREFV60_SDMMC_1V8_3V_GPIO; | ||
281 | sdi0_configure(parent); | 230 | sdi0_configure(parent); |
282 | /* WLAN SDIO channel */ | 231 | /* WLAN SDIO channel */ |
283 | db8500_add_sdi1(parent, &mop500_sdi1_data, U8500_SDI_V2_PERIPHID); | 232 | db8500_add_sdi1(parent, &mop500_sdi1_data, U8500_SDI_V2_PERIPHID); |