From 52525d352a8939eca5a98567e973e37c322dae2e Mon Sep 17 00:00:00 2001 From: Gary King Date: Wed, 14 Jul 2010 20:41:23 -0700 Subject: [PATCH] tegra-sdhci: treat -1 as invalid card detect GPIO 0 is a valid GPIO number (GPIO_PA0), so the check in the tegra SDHCI driver for a valid card detect pin should compare against -1 instead Change-Id: I47ad31eaf89472b2e6938978d72a9d0b92a74958 Signed-off-by: Gary King --- drivers/mmc/host/sdhci-tegra.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mmc/host/sdhci-tegra.c b/drivers/mmc/host/sdhci-tegra.c index 3d7f6628bc44..e6c8f2405c44 100644 --- a/drivers/mmc/host/sdhci-tegra.c +++ b/drivers/mmc/host/sdhci-tegra.c @@ -128,7 +128,7 @@ static int __devinit tegra_sdhci_probe(struct platform_device *pdev) platform_set_drvdata(pdev, host); - if (plat->cd_gpio) { + if (plat->cd_gpio != -1) { rc = request_irq(gpio_to_irq(plat->cd_gpio), carddetect_irq, IRQF_TRIGGER_FALLING | IRQF_TRIGGER_RISING, mmc_hostname(sdhci->mmc), sdhci); -- 2.34.1