mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 10:41:38 -04:00
Merge branch 'pm-core'
* pm-core: driver core: Avoid NULL pointer dereferences in device_is_bound() platform: Do not detach from PM domains on shutdown USB / PM: Allow USB devices to remain runtime-suspended when sleeping PM / sleep: Go direct_complete if driver has no callbacks PM / Domains: add setter for dev.pm_domain device core: add device_is_bound()
This commit is contained in:
commit
6efd3f8cde
18 changed files with 132 additions and 23 deletions
|
|
@ -31,6 +31,7 @@
|
|||
#include <linux/jiffies.h>
|
||||
#include <linux/interrupt.h>
|
||||
|
||||
#include <linux/pm_domain.h>
|
||||
#include <linux/pm_runtime.h>
|
||||
|
||||
#include <linux/mei.h>
|
||||
|
|
@ -436,7 +437,7 @@ static inline void mei_me_set_pm_domain(struct mei_device *dev)
|
|||
dev->pg_domain.ops.runtime_resume = mei_me_pm_runtime_resume;
|
||||
dev->pg_domain.ops.runtime_idle = mei_me_pm_runtime_idle;
|
||||
|
||||
pdev->dev.pm_domain = &dev->pg_domain;
|
||||
dev_pm_domain_set(&pdev->dev, &dev->pg_domain);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -448,7 +449,7 @@ static inline void mei_me_set_pm_domain(struct mei_device *dev)
|
|||
static inline void mei_me_unset_pm_domain(struct mei_device *dev)
|
||||
{
|
||||
/* stop using pm callbacks if any */
|
||||
dev->dev->pm_domain = NULL;
|
||||
dev_pm_domain_set(dev->dev, NULL);
|
||||
}
|
||||
|
||||
static const struct dev_pm_ops mei_me_pm_ops = {
|
||||
|
|
|
|||
|
|
@ -27,6 +27,7 @@
|
|||
#include <linux/jiffies.h>
|
||||
#include <linux/interrupt.h>
|
||||
#include <linux/workqueue.h>
|
||||
#include <linux/pm_domain.h>
|
||||
#include <linux/pm_runtime.h>
|
||||
|
||||
#include <linux/mei.h>
|
||||
|
|
@ -388,7 +389,7 @@ static inline void mei_txe_set_pm_domain(struct mei_device *dev)
|
|||
dev->pg_domain.ops.runtime_resume = mei_txe_pm_runtime_resume;
|
||||
dev->pg_domain.ops.runtime_idle = mei_txe_pm_runtime_idle;
|
||||
|
||||
pdev->dev.pm_domain = &dev->pg_domain;
|
||||
dev_pm_domain_set(&pdev->dev, &dev->pg_domain);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -400,7 +401,7 @@ static inline void mei_txe_set_pm_domain(struct mei_device *dev)
|
|||
static inline void mei_txe_unset_pm_domain(struct mei_device *dev)
|
||||
{
|
||||
/* stop using pm callbacks if any */
|
||||
dev->dev->pm_domain = NULL;
|
||||
dev_pm_domain_set(dev->dev, NULL);
|
||||
}
|
||||
|
||||
static const struct dev_pm_ops mei_txe_pm_ops = {
|
||||
|
|
|
|||
Loading…
Reference in a new issue