Commit 41c95b04 authored by Tomas Winkler's avatar Tomas Winkler Committed by Greg Kroah-Hartman

mei: add also write waiting list to runtime pm blockers

The io callback is clear from write_waitling_list after
we receive interrupt from the hw to ack the write completion.
We need to wait for this interrupt deliver before we try
to enter low power state
Signed-off-by: default avatarTomas Winkler <tomas.winkler@intel.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent a1809d38
...@@ -361,13 +361,15 @@ bool mei_write_is_idle(struct mei_device *dev) ...@@ -361,13 +361,15 @@ bool mei_write_is_idle(struct mei_device *dev)
{ {
bool idle = (dev->dev_state == MEI_DEV_ENABLED && bool idle = (dev->dev_state == MEI_DEV_ENABLED &&
list_empty(&dev->ctrl_wr_list.list) && list_empty(&dev->ctrl_wr_list.list) &&
list_empty(&dev->write_list.list)); list_empty(&dev->write_list.list) &&
list_empty(&dev->write_waiting_list.list));
dev_dbg(dev->dev, "write pg: is idle[%d] state=%s ctrl=%d write=%d\n", dev_dbg(dev->dev, "write pg: is idle[%d] state=%s ctrl=%01d write=%01d wwait=%01d\n",
idle, idle,
mei_dev_state_str(dev->dev_state), mei_dev_state_str(dev->dev_state),
list_empty(&dev->ctrl_wr_list.list), list_empty(&dev->ctrl_wr_list.list),
list_empty(&dev->write_list.list)); list_empty(&dev->write_list.list),
list_empty(&dev->write_waiting_list.list));
return idle; return idle;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment