]> git.baikalelectronics.ru Git - kernel.git/commit
PM / Runtime: Fix error path for prepare
authorUlf Hansson <ulf.hansson@linaro.org>
Wed, 13 Nov 2013 14:45:03 +0000 (15:45 +0100)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 13 Nov 2013 23:48:19 +0000 (00:48 +0100)
commit9599bb7e12b9ef1876060b34930004ca25596045
tree03974c3bb35582ce372d66b6017413146c7e2be1
parente91d87c4f2c134154765165acf83fc244c8e3c9c
PM / Runtime: Fix error path for prepare

If a device prepare callback for some reason would fail, the PM core
prevented the device from going inactive forever.

In this case, to reverse the pm_runtime_get_noresume() we invokes the
asyncronous pm_runtime_put(), thus restoring the usage count.

Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/base/power/main.c