mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-02 21:26:44 +07:00
mmc: Do not call get_cd for non removable cards
Non removable cards are always present, so do not call get_cd for them. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Acked-by: Ulf Hansson <ulf.hansson@linaro.org> Signed-off-by: Chris Ball <cjb@laptop.org>
This commit is contained in:
parent
07c001c119
commit
c1b55bfcb3
@ -2460,7 +2460,8 @@ void mmc_rescan(struct work_struct *work)
|
||||
*/
|
||||
mmc_bus_put(host);
|
||||
|
||||
if (host->ops->get_cd && host->ops->get_cd(host) == 0) {
|
||||
if (!(host->caps & MMC_CAP_NONREMOVABLE) && host->ops->get_cd &&
|
||||
host->ops->get_cd(host) == 0) {
|
||||
mmc_claim_host(host);
|
||||
mmc_power_off(host);
|
||||
mmc_release_host(host);
|
||||
|
Loading…
Reference in New Issue
Block a user