diff options
Diffstat (limited to 'arch/arm/mach-pxa/littleton.c')
-rw-r--r-- | arch/arm/mach-pxa/littleton.c | 51 |
1 files changed, 11 insertions, 40 deletions
diff --git a/arch/arm/mach-pxa/littleton.c b/arch/arm/mach-pxa/littleton.c index 55b3788fd1ae..f28c1715b910 100644 --- a/arch/arm/mach-pxa/littleton.c +++ b/arch/arm/mach-pxa/littleton.c | |||
@@ -44,10 +44,10 @@ | |||
44 | #include <mach/ssp.h> | 44 | #include <mach/ssp.h> |
45 | #include <mach/mmc.h> | 45 | #include <mach/mmc.h> |
46 | #include <mach/pxa2xx_spi.h> | 46 | #include <mach/pxa2xx_spi.h> |
47 | #include <plat/i2c.h> | ||
48 | #include <mach/pxa27x_keypad.h> | 47 | #include <mach/pxa27x_keypad.h> |
49 | #include <mach/pxa3xx_nand.h> | ||
50 | #include <mach/littleton.h> | 48 | #include <mach/littleton.h> |
49 | #include <plat/i2c.h> | ||
50 | #include <plat/pxa3xx_nand.h> | ||
51 | 51 | ||
52 | #include "generic.h" | 52 | #include "generic.h" |
53 | 53 | ||
@@ -265,45 +265,12 @@ static inline void littleton_init_keypad(void) {} | |||
265 | #endif | 265 | #endif |
266 | 266 | ||
267 | #if defined(CONFIG_MMC_PXA) || defined(CONFIG_MMC_PXA_MODULE) | 267 | #if defined(CONFIG_MMC_PXA) || defined(CONFIG_MMC_PXA_MODULE) |
268 | static int littleton_mci_init(struct device *dev, | ||
269 | irq_handler_t littleton_detect_int, void *data) | ||
270 | { | ||
271 | int err, gpio_cd = GPIO_MMC1_CARD_DETECT; | ||
272 | |||
273 | err = gpio_request(gpio_cd, "mmc card detect"); | ||
274 | if (err) | ||
275 | goto err_request_cd; | ||
276 | |||
277 | gpio_direction_input(gpio_cd); | ||
278 | |||
279 | err = request_irq(gpio_to_irq(gpio_cd), littleton_detect_int, | ||
280 | IRQF_TRIGGER_RISING | IRQF_TRIGGER_FALLING, | ||
281 | "mmc card detect", data); | ||
282 | if (err) { | ||
283 | dev_err(dev, "failed to request card detect IRQ\n"); | ||
284 | goto err_request_irq; | ||
285 | } | ||
286 | return 0; | ||
287 | |||
288 | err_request_irq: | ||
289 | gpio_free(gpio_cd); | ||
290 | err_request_cd: | ||
291 | return err; | ||
292 | } | ||
293 | |||
294 | static void littleton_mci_exit(struct device *dev, void *data) | ||
295 | { | ||
296 | int gpio_cd = GPIO_MMC1_CARD_DETECT; | ||
297 | |||
298 | free_irq(gpio_to_irq(gpio_cd), data); | ||
299 | gpio_free(gpio_cd); | ||
300 | } | ||
301 | |||
302 | static struct pxamci_platform_data littleton_mci_platform_data = { | 268 | static struct pxamci_platform_data littleton_mci_platform_data = { |
303 | .detect_delay = 20, | 269 | .detect_delay = 20, |
304 | .ocr_mask = MMC_VDD_32_33 | MMC_VDD_33_34, | 270 | .ocr_mask = MMC_VDD_32_33 | MMC_VDD_33_34, |
305 | .init = littleton_mci_init, | 271 | .gpio_card_detect = GPIO_MMC1_CARD_DETECT, |
306 | .exit = littleton_mci_exit, | 272 | .gpio_card_ro = -1, |
273 | .gpio_power = -1, | ||
307 | }; | 274 | }; |
308 | 275 | ||
309 | static void __init littleton_init_mmc(void) | 276 | static void __init littleton_init_mmc(void) |
@@ -446,6 +413,10 @@ static void __init littleton_init(void) | |||
446 | /* initialize MFP configurations */ | 413 | /* initialize MFP configurations */ |
447 | pxa3xx_mfp_config(ARRAY_AND_SIZE(littleton_mfp_cfg)); | 414 | pxa3xx_mfp_config(ARRAY_AND_SIZE(littleton_mfp_cfg)); |
448 | 415 | ||
416 | pxa_set_ffuart_info(NULL); | ||
417 | pxa_set_btuart_info(NULL); | ||
418 | pxa_set_stuart_info(NULL); | ||
419 | |||
449 | /* | 420 | /* |
450 | * Note: we depend bootloader set the correct | 421 | * Note: we depend bootloader set the correct |
451 | * value to MSC register for SMC91x. | 422 | * value to MSC register for SMC91x. |