Date: | 2010-07-20 01:34:59 (13 years 4 months ago) |
---|---|
Author: | Maarten ter Huurne |
Commit: | a267b41e577b2c787bd61993d0359b0a19c559ca |
Message: | MMC: jz4740: Fixed card change detection. The GPIO validity check was reversed. Also removed some dead code. |
Files: |
drivers/mmc/host/jz4740_mmc.c (1 diff) |
Change Details
drivers/mmc/host/jz4740_mmc.c | ||
---|---|---|
761 | 761 | static int __devinit jz4740_mmc_request_cd_irq(struct platform_device *pdev, |
762 | 762 | struct jz4740_mmc_host *host) |
763 | 763 | { |
764 | int ret; | |
765 | 764 | struct jz4740_mmc_platform_data *pdata = pdev->dev.platform_data; |
766 | 765 | |
767 | if (gpio_is_valid(pdata->gpio_card_detect)) | |
766 | if (!gpio_is_valid(pdata->gpio_card_detect)) | |
768 | 767 | return 0; |
769 | 768 | |
770 | 769 | host->card_detect_irq = gpio_to_irq(pdata->gpio_card_detect); |
771 | ||
772 | 770 | if (host->card_detect_irq < 0) { |
773 | 771 | dev_warn(&pdev->dev, "Failed to get card detect irq\n"); |
774 | 772 | return 0; |
775 | 773 | } |
774 | ||
776 | 775 | return request_irq(host->card_detect_irq, jz4740_mmc_card_detect_irq, |
777 | 776 | IRQF_TRIGGER_RISING | IRQF_TRIGGER_FALLING, |
778 | 777 | "MMC card detect", host); |
779 | ||
780 | ||
781 | return ret; | |
782 | 778 | } |
783 | 779 | |
784 | 780 | static void jz4740_mmc_free_gpios(struct platform_device *pdev) |
Branches:
ben-wpan
ben-wpan-stefan
5396a9238205f20f811ea57898980d3ca82df0b6
jz-2.6.34
jz-2.6.34-rc5
jz-2.6.34-rc6
jz-2.6.34-rc7
jz-2.6.35
jz-2.6.36
jz-2.6.37
jz-2.6.38
jz-2.6.39
jz-3.0
jz-3.1
jz-3.11
jz-3.12
jz-3.13
jz-3.15
jz-3.16
jz-3.18-dt
jz-3.2
jz-3.3
jz-3.4
jz-3.5
jz-3.6
jz-3.6-rc2-pwm
jz-3.9
jz-3.9-clk
jz-3.9-rc8
jz47xx
jz47xx-2.6.38
master
Tags:
od-2011-09-04
od-2011-09-18
v2.6.34-rc5
v2.6.34-rc6
v2.6.34-rc7
v3.9