diff options
Diffstat (limited to 'arch/arm/mach-shmobile/board-ag5evm.c')
-rw-r--r-- | arch/arm/mach-shmobile/board-ag5evm.c | 22 |
1 files changed, 2 insertions, 20 deletions
diff --git a/arch/arm/mach-shmobile/board-ag5evm.c b/arch/arm/mach-shmobile/board-ag5evm.c index cb224a344af0..0891ec6e27f5 100644 --- a/arch/arm/mach-shmobile/board-ag5evm.c +++ b/arch/arm/mach-shmobile/board-ag5evm.c | |||
@@ -365,23 +365,13 @@ static struct platform_device mipidsi0_device = { | |||
365 | }; | 365 | }; |
366 | 366 | ||
367 | /* SDHI0 */ | 367 | /* SDHI0 */ |
368 | static irqreturn_t ag5evm_sdhi0_gpio_cd(int irq, void *arg) | ||
369 | { | ||
370 | struct device *dev = arg; | ||
371 | struct sh_mobile_sdhi_info *info = dev->platform_data; | ||
372 | struct tmio_mmc_data *pdata = info->pdata; | ||
373 | |||
374 | tmio_mmc_cd_wakeup(pdata); | ||
375 | |||
376 | return IRQ_HANDLED; | ||
377 | } | ||
378 | |||
379 | static struct sh_mobile_sdhi_info sdhi0_info = { | 368 | static struct sh_mobile_sdhi_info sdhi0_info = { |
380 | .dma_slave_tx = SHDMA_SLAVE_SDHI0_TX, | 369 | .dma_slave_tx = SHDMA_SLAVE_SDHI0_TX, |
381 | .dma_slave_rx = SHDMA_SLAVE_SDHI0_RX, | 370 | .dma_slave_rx = SHDMA_SLAVE_SDHI0_RX, |
382 | .tmio_flags = TMIO_MMC_HAS_IDLE_WAIT, | 371 | .tmio_flags = TMIO_MMC_HAS_IDLE_WAIT | TMIO_MMC_USE_GPIO_CD, |
383 | .tmio_caps = MMC_CAP_SD_HIGHSPEED, | 372 | .tmio_caps = MMC_CAP_SD_HIGHSPEED, |
384 | .tmio_ocr_mask = MMC_VDD_27_28 | MMC_VDD_28_29, | 373 | .tmio_ocr_mask = MMC_VDD_27_28 | MMC_VDD_28_29, |
374 | .cd_gpio = GPIO_PORT251, | ||
385 | }; | 375 | }; |
386 | 376 | ||
387 | static struct resource sdhi0_resources[] = { | 377 | static struct resource sdhi0_resources[] = { |
@@ -557,7 +547,6 @@ static void __init ag5evm_init(void) | |||
557 | lcd_backlight_reset(); | 547 | lcd_backlight_reset(); |
558 | 548 | ||
559 | /* enable SDHI0 on CN15 [SD I/F] */ | 549 | /* enable SDHI0 on CN15 [SD I/F] */ |
560 | gpio_request(GPIO_FN_SDHICD0, NULL); | ||
561 | gpio_request(GPIO_FN_SDHIWP0, NULL); | 550 | gpio_request(GPIO_FN_SDHIWP0, NULL); |
562 | gpio_request(GPIO_FN_SDHICMD0, NULL); | 551 | gpio_request(GPIO_FN_SDHICMD0, NULL); |
563 | gpio_request(GPIO_FN_SDHICLK0, NULL); | 552 | gpio_request(GPIO_FN_SDHICLK0, NULL); |
@@ -566,13 +555,6 @@ static void __init ag5evm_init(void) | |||
566 | gpio_request(GPIO_FN_SDHID0_1, NULL); | 555 | gpio_request(GPIO_FN_SDHID0_1, NULL); |
567 | gpio_request(GPIO_FN_SDHID0_0, NULL); | 556 | gpio_request(GPIO_FN_SDHID0_0, NULL); |
568 | 557 | ||
569 | if (!request_irq(intcs_evt2irq(0x3c0), ag5evm_sdhi0_gpio_cd, | ||
570 | IRQF_TRIGGER_FALLING | IRQF_TRIGGER_RISING, | ||
571 | "sdhi0 cd", &sdhi0_device.dev)) | ||
572 | sdhi0_info.tmio_flags |= TMIO_MMC_HAS_COLD_CD; | ||
573 | else | ||
574 | pr_warn("Unable to setup SDHI0 GPIO IRQ\n"); | ||
575 | |||
576 | /* enable SDHI1 on CN4 [WLAN I/F] */ | 558 | /* enable SDHI1 on CN4 [WLAN I/F] */ |
577 | gpio_request(GPIO_FN_SDHICLK1, NULL); | 559 | gpio_request(GPIO_FN_SDHICLK1, NULL); |
578 | gpio_request(GPIO_FN_SDHICMD1_PU, NULL); | 560 | gpio_request(GPIO_FN_SDHICMD1_PU, NULL); |