Skip to content

Commit

Permalink
usb: dwc3: core: allow device to runtime_suspend several times
Browse files Browse the repository at this point in the history
After going through runtime_suspend/runtime_resume
cycle once we would be left with an unbalanced
pm_runtime_get() call. Fix that by making sure that
we try to suspend right after resuming so things are
balanced and device can runtime_suspend again.

Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
  • Loading branch information
Felipe Balbi committed Aug 22, 2016
1 parent f6c274e commit b74c2d8
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/usb/dwc3/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1192,6 +1192,7 @@ static int dwc3_runtime_resume(struct device *dev)
}

pm_runtime_mark_last_busy(dev);
pm_runtime_put(dev);

return 0;
}
Expand Down

0 comments on commit b74c2d8

Please sign in to comment.