diff options
| author | Jack Pham <jackp@codeaurora.org> | 2016-09-21 12:03:29 -0700 |
|---|---|---|
| committer | Jack Pham <jackp@codeaurora.org> | 2016-10-14 17:51:45 -0700 |
| commit | b08f588476adf8952efd3ae969787c5be1519f42 (patch) | |
| tree | c443cde36fd0b81937cefb887bedd836bd483ae4 /lib/mpi/mpicoder.c | |
| parent | 3bf9e3840071d88b78f70a076da9bdd6c020c474 (diff) | |
usb: pd: Prevent sleep when state machine in progress
With PM autosleep enabled, the system may aggressively enter
and re-enter suspend in between calls to queue_work() and
when the state machine function gets executed, which may
at best result in numerous suspend/resume cycles and at
worse starve the PD state machine from even executing.
Fix this by calling pm_stay_awake() whenever the work is
queued and relinquish with pm_relax() when no further work
is to be done.
Change-Id: I71d8ea0c69a7b174c2280f92d1f5342e5e50d9b0
Signed-off-by: Jack Pham <jackp@codeaurora.org>
Diffstat (limited to 'lib/mpi/mpicoder.c')
0 files changed, 0 insertions, 0 deletions
