From c1d677bd664f7760e883478f74e4f5b540a3707d Mon Sep 17 00:00:00 2001 From: Johan Rudholm Date: Thu, 23 Aug 2012 13:40:55 +0200 Subject: [PATCH] --- yaml --- r: 332814 b: refs/heads/master c: 3339d1e33185798a45dbdb5ea6c0bec1c27ca5fd h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/mmc/core/core.c | 5 +++++ trunk/include/linux/mmc/host.h | 1 + 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 44e77230c4dd..2ae32d31975f 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 36c179a98a0755b98153e8f4ae08243fbfcd18ff +refs/heads/master: 3339d1e33185798a45dbdb5ea6c0bec1c27ca5fd diff --git a/trunk/drivers/mmc/core/core.c b/trunk/drivers/mmc/core/core.c index 835c9f001a10..af2c4d2fd69e 100644 --- a/trunk/drivers/mmc/core/core.c +++ b/trunk/drivers/mmc/core/core.c @@ -2053,6 +2053,11 @@ void mmc_rescan(struct work_struct *work) if (host->rescan_disable) return; + /* If there is a non-removable card registered, only scan once */ + if ((host->caps & MMC_CAP_NONREMOVABLE) && host->rescan_entered) + return; + host->rescan_entered = 1; + mmc_bus_get(host); /* diff --git a/trunk/include/linux/mmc/host.h b/trunk/include/linux/mmc/host.h index f578a71d82a6..d5d9bd4c5aa8 100644 --- a/trunk/include/linux/mmc/host.h +++ b/trunk/include/linux/mmc/host.h @@ -300,6 +300,7 @@ struct mmc_host { #endif int rescan_disable; /* disable card detection */ + int rescan_entered; /* used with nonremovable devices */ struct mmc_card *card; /* device attached to this host */