summaryrefslogtreecommitdiffstats
path: root/libsuspend/autosuspend_wakeup_count.c
Commit message (Collapse)AuthorAgeFilesLines
* Convert autosuspend_wakeup_count.c to cppSteve Paik2017-12-201-211/+0
| | | | | | | | Change this file to cpp before cleaning it up. Bug: 70669809 Test: Suspend works Change-Id: Ice927dbb205447a94f33b417e32f7c2cd79613eb
* Create wrapper function for set_wakeup_callbackSteve Paik2017-12-181-13/+9
| | | | | | | Bug: 70669809 Test: Compiles Change-Id: I55f8b9995c2d872504b586addb07a18206da7fbe
* Fix LOG() messages to drop \nSteve Paik2017-12-141-21/+21
| | | | | | Bug: 70669809 Test: It's gone Change-Id: Id66776a229be677c89968d1e0dc81fc8b4b7de5d
* Revert "Revert "libsuspend: move to exponential backoff""Ajay Dudani2017-04-181-5/+19
| | | | | | | | | Test: Left device overnight, libsuspend exponential backoff path was exercised multiple time and device went into suspend. This reverts commit 23c8bab0243bc6e7be8b95702c262c354009d56a. Change-Id: Ifa5c41bc1ca5da7baa28b216d70305c98806bf36
* Merge "liblog: use log/log.h when utilizing ALOG macros" am: 01e12b4ee7Mark Salyzyn2017-01-111-1/+1
|\ | | | | | | | | | | am: c3b346ea93 Change-Id: I0ee5652701e23d751def8bac82534af530ea5dc8
| * liblog: use log/log.h when utilizing ALOG macrosMark Salyzyn2017-01-111-1/+1
| | | | | | | | | | | | Test: compile Bug: 30465923 Change-Id: Id6d76510819ebd88c3f5003d00d73a0dbe85e943
* | Revert "libsuspend: move to exponential backoff" am: 23c8bab024Tim Murray2016-10-181-19/+5
|\ \ | |/ |/| | | | | | | am: 4dcd461945 Change-Id: Ie1087acf944c43ab2c4f02a63817563d6125393f
| * Revert "libsuspend: move to exponential backoff"Tim Murray2016-10-181-19/+5
| | | | | | | | | | | | | | | | This reverts commit fb896944b6a78d951c8442b444af860a28117e5c. bug 32180327 Change-Id: Ic26bdffac6c56b102348f5393e6eb5d895960d7e
* | libsuspend: move to exponential backoff am: fb896944b6Tim Murray2016-10-121-5/+19
|\| | | | | | | | | | | am: cf11830695 Change-Id: Ic3289a6cf433ee1c0c9b468ea8380493663ed84f
| * libsuspend: move to exponential backoffTim Murray2016-10-111-5/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | If for some reason the system can't suspend (usually a driver bug), libsuspend will currently attempt to retry suspend after 100ms. Because entering suspend takes a significant amount of CPU time, this can be extremely expensive and be a major contributor to rapid battery drain. Move autosuspend to use exponential backoff if the previous suspend attempt failed. bug 32092914 Change-Id: I3e9e944f290de5f1853a02e3f61721ba9159df46
* | system/core Replace cutils/log.h with android/log.hMark Salyzyn2016-09-301-3/+4
|/ | | | | | | | | | | Should use android/log.h instead of cutils/log.h as a good example to all others. Adjust header order to comply with Android Coding standards. Test: Compile Bug: 26552300 Bug: 31289077 Change-Id: I2c9cbbbd64d8dccf2d44356361d9742e4a9b9031
* Adds a parameter to the wakeup_callback to report sucessful wakeup or ↵Ruchi Kandoi2015-06-251-9/+10
| | | | | | | | | | | suspend aborts. Adds the call to wakeup_callback when the write to the /sys/power/state fails. This will help userspace account for the suspend aborts. Bug: 17478088 Bug: 18179405 Change-Id: Icd1194cfbaf61044ca0b2fe63a10a4c52e1535bc
* Add TEMP_FAILURE_RETRY to libsuspend.Jeff Brown2015-05-181-5/+6
| | | | | | | | | In testing, I observed one instance of a call failing due to a signal sent to the process. This could happen at various times so it's better to be safe than sorry. Bug: 20534809 Change-Id: I42242087300d8b840a50aec34aa6b2e1507cab50
* Add ability to have a callback when wakeups happen.Dianne Hackborn2014-03-071-0/+16
| | | | Change-Id: I02ff0e035bf8a97bd1a3b6b1699181fc3a137d79
* Fix unused param warningEdwin Vane2012-08-021-1/+1
| | | | | | | | | libsuspend had only a single warning in the clang build. Fixing it to make the build clean. Change-Id: Iaac5f9144b6e6cb122141c6416056c1b2c9aa98e Author: Edwin Vane <edwin.vane@intel.com> Reviewed-by: Kevin P Schoedel <kevin.p.schoedel@intel.com>
* libsuspend: create new library to handle triggering suspendColin Cross2012-05-071-0/+182
libsuspend provides functions autosuspend_enable() and autosuspend_disable() to trigger suspend on a variety of different kernels. Change-Id: I5dc28fb51532fa7c514330f1cfde7698d31d734c