summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTodd Poynor2014-03-04 15:11:21 -0600
committerTodd Poynor2014-03-04 22:02:53 -0600
commit6f26891d67a55515b46c3da38d63c4d41c3cfefc (patch)
tree74f3fa08eea778262c145ee7e7c9e3ef64063b3a /libsuspend
parentd030033a39196bf377a70ceb0ade7d40fa917664 (diff)
downloadplatform-system-core-6f26891d67a55515b46c3da38d63c4d41c3cfefc.tar.gz
platform-system-core-6f26891d67a55515b46c3da38d63c4d41c3cfefc.tar.xz
platform-system-core-6f26891d67a55515b46c3da38d63c4d41c3cfefc.zip
libsuspend: use wakeup count interface for system suspend
Use the wakeup count interface for requesting suspend, instead of autosleep, to allow userspace to collect stats on suspend/resume activity. Change-Id: I44b5ef031b2bdc5b09c904fb2adbbe16370c2984
Diffstat (limited to 'libsuspend')
-rw-r--r--libsuspend/autosuspend.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libsuspend/autosuspend.c b/libsuspend/autosuspend.c
index eb1f66e37..edd100711 100644
--- a/libsuspend/autosuspend.c
+++ b/libsuspend/autosuspend.c
@@ -38,10 +38,13 @@ static int autosuspend_init(void)
38 goto out; 38 goto out;
39 } 39 }
40 40
41/* Remove autosleep so userspace can manager suspend/resume and keep stats */
42#if 0
41 autosuspend_ops = autosuspend_autosleep_init(); 43 autosuspend_ops = autosuspend_autosleep_init();
42 if (autosuspend_ops) { 44 if (autosuspend_ops) {
43 goto out; 45 goto out;
44 } 46 }
47#endif
45 48
46 autosuspend_ops = autosuspend_wakeup_count_init(); 49 autosuspend_ops = autosuspend_wakeup_count_init();
47 if (autosuspend_ops) { 50 if (autosuspend_ops) {