aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2011-09-20 19:58:51 -0700
committerPraneeth Bajjuri <praneeth@ti.com>2011-09-20 19:59:03 -0700
commite18e2789803316172c4d2a640c747343ade60a6e (patch)
tree4afaa5c6242b18c5d4f3b3232088532be6572034 /include
parent5093cdd576c91f012b0b72fe9ea4ee35f1cd6541 (diff)
mmc: core: host: only use wakelock for detect work
There is no need to take a wakelock for delayed lazy disable work, it will be cancelled in the suspend handler and force disabled. Only take the wakelock when the detect work is queued, and make sure to drop the wakelock if the work is cancelled. Change-Id: I1e507a5f98848954ea21d45e23b6192c3132a349 Signed-off-by: Colin Cross <ccross@android.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/mmc/host.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/mmc/host.h b/include/linux/mmc/host.h
index a19facadb1a..51128f8a577 100644
--- a/include/linux/mmc/host.h
+++ b/include/linux/mmc/host.h
@@ -12,6 +12,7 @@
#include <linux/leds.h>
#include <linux/sched.h>
+#include <linux/wakelock.h>
#include <linux/mmc/core.h>
#include <linux/mmc/pm.h>
@@ -280,6 +281,7 @@ struct mmc_host {
int claim_cnt; /* "claim" nesting count */
struct delayed_work detect;
+ struct wake_lock detect_wake_lock;
const struct mmc_bus_ops *bus_ops; /* current bus driver */
unsigned int bus_refs; /* reference counter */