From: kfx Date: Mon, 18 Apr 2011 09:11:26 +0000 (+0800) Subject: update sdmmc driver for no det gpio X-Git-Tag: firefly_0821_release~10461 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=35257416c8d39ad92f0144f78c9cc1360cea0521;p=firefly-linux-kernel-4.4.55.git update sdmmc driver for no det gpio --- diff --git a/drivers/mmc/host/rk29_sdmmc.c b/drivers/mmc/host/rk29_sdmmc.c index bdb8c98825f8..8db65e955d72 100755 --- a/drivers/mmc/host/rk29_sdmmc.c +++ b/drivers/mmc/host/rk29_sdmmc.c @@ -1363,7 +1363,7 @@ static int rk29_sdmmc_suspend(struct platform_device *pdev, pm_message_t state) struct rk29_sdmmc *host = platform_get_drvdata(pdev); dev_info(host->dev, "Enter rk29_sdmmc_suspend\n"); - if(host->mmc && !host->is_sdio){ + if(host->mmc && !host->is_sdio && host->gpio_det != INVALID_GPIO){ ret = mmc_suspend_host(host->mmc, state); if(!host->enable_sd_warkup) free_irq(host->gpio_irq, host); @@ -1383,7 +1383,7 @@ static int rk29_sdmmc_resume(struct platform_device *pdev) dev_info(host->dev, "Exit rk29_sdmmc_suspend\n"); clk_enable(host->clk); rk29_sdmmc_write(host->regs, SDMMC_CLKENA, 1); - if(host->mmc && !host->is_sdio){ + if(host->mmc && !host->is_sdio && host->gpio_det != INVALID_GPIO){ if(!host->enable_sd_warkup) ret = request_irq(host->gpio_irq, rk29_sdmmc_detect_change_isr,