diff options
author | Alexander Usyskin <alexander.usyskin@intel.com> | 2016-11-24 13:34:02 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-11-29 20:15:30 +0100 |
commit | d5f8e166c25750adc147b0adf64a62a91653438a (patch) | |
tree | 6edbb31bad5d94b19ca22b5be00bc30fd495a295 | |
parent | ec98960e0bbbe49b569b09c14ccd82efeb232dc8 (diff) | |
download | op-kernel-dev-d5f8e166c25750adc147b0adf64a62a91653438a.zip op-kernel-dev-d5f8e166c25750adc147b0adf64a62a91653438a.tar.gz |
mei: request async autosuspend at the end of enumeration
pm_runtime_autosuspend can take synchronous or asynchronous
paths, Because we are calling pm_runtime_mark_last_busy just before
this most of the cases it takes the asynchronous way. However,
when the FW or driver resets during already running runtime suspend,
the call will result in calling to the driver's rpm callback and results
in a deadlock on device_lock.
The simplest fix is to replace pm_runtime_autosuspend with
asynchronous pm_request_autosuspend.
Cc: <stable@vger.kernel.org> # 4.4+
Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/misc/mei/client.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/misc/mei/client.c b/drivers/misc/mei/client.c index 9635b14..391936c 100644 --- a/drivers/misc/mei/client.c +++ b/drivers/misc/mei/client.c @@ -691,7 +691,7 @@ void mei_host_client_init(struct mei_device *dev) pm_runtime_mark_last_busy(dev->dev); dev_dbg(dev->dev, "rpm: autosuspend\n"); - pm_runtime_autosuspend(dev->dev); + pm_request_autosuspend(dev->dev); } /** |