summaryrefslogtreecommitdiff
path: root/drivers/misc/mei/hbm.c
diff options
context:
space:
mode:
authorTomas Winkler <tomas.winkler@intel.com>2014-03-18 20:52:02 (GMT)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-05-03 23:20:24 (GMT)
commit180ea05bcedbd67bb22a426bb8d831075727e34a (patch)
tree05e5918348bc422a5df912204b6f8c36f44c3e13 /drivers/misc/mei/hbm.c
parenta532bbedc85ff3b834ba81e49163a3f543be1775 (diff)
downloadlinux-180ea05bcedbd67bb22a426bb8d831075727e34a.tar.xz
mei: me: add runtime pm framework
Add runtime pm framework for ME devices. The runtime pm handlers are used to run me power gating isolation protocol Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/mei/hbm.c')
-rw-r--r--drivers/misc/mei/hbm.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/misc/mei/hbm.c b/drivers/misc/mei/hbm.c
index a725365..b9a4bb5 100644
--- a/drivers/misc/mei/hbm.c
+++ b/drivers/misc/mei/hbm.c
@@ -19,6 +19,7 @@
#include <linux/sched.h>
#include <linux/wait.h>
#include <linux/mei.h>
+#include <linux/pm_runtime.h>
#include "mei_dev.h"
#include "hbm.h"
@@ -742,6 +743,13 @@ int mei_hbm_dispatch(struct mei_device *dev, struct mei_msg_hdr *hdr)
dev->pg_event = MEI_PG_EVENT_RECEIVED;
if (waitqueue_active(&dev->wait_pg))
wake_up(&dev->wait_pg);
+ else
+ /*
+ * If the driver is not waiting on this then
+ * this is HW initiated exit from PG.
+ * Start runtime pm resume sequence to exit from PG.
+ */
+ pm_request_resume(&dev->pdev->dev);
break;
case HOST_CLIENT_PROPERTIES_RES_CMD: