|
@@ -1534,10 +1534,30 @@ static int intel_resume_prepare(struct drm_i915_private *dev_priv,
|
|
}
|
|
}
|
|
|
|
|
|
static const struct dev_pm_ops i915_pm_ops = {
|
|
static const struct dev_pm_ops i915_pm_ops = {
|
|
|
|
+ /*
|
|
|
|
+ * S0ix (via system suspend) and S3 event handlers [PMSG_SUSPEND,
|
|
|
|
+ * PMSG_RESUME]
|
|
|
|
+ */
|
|
.suspend = i915_pm_suspend,
|
|
.suspend = i915_pm_suspend,
|
|
.suspend_late = i915_pm_suspend_late,
|
|
.suspend_late = i915_pm_suspend_late,
|
|
.resume_early = i915_pm_resume_early,
|
|
.resume_early = i915_pm_resume_early,
|
|
.resume = i915_pm_resume,
|
|
.resume = i915_pm_resume,
|
|
|
|
+
|
|
|
|
+ /*
|
|
|
|
+ * S4 event handlers
|
|
|
|
+ * @freeze, @freeze_late : called (1) before creating the
|
|
|
|
+ * hibernation image [PMSG_FREEZE] and
|
|
|
|
+ * (2) after rebooting, before restoring
|
|
|
|
+ * the image [PMSG_QUIESCE]
|
|
|
|
+ * @thaw, @thaw_early : called (1) after creating the hibernation
|
|
|
|
+ * image, before writing it [PMSG_THAW]
|
|
|
|
+ * and (2) after failing to create or
|
|
|
|
+ * restore the image [PMSG_RECOVER]
|
|
|
|
+ * @poweroff, @poweroff_late: called after writing the hibernation
|
|
|
|
+ * image, before rebooting [PMSG_HIBERNATE]
|
|
|
|
+ * @restore, @restore_early : called after rebooting and restoring the
|
|
|
|
+ * hibernation image [PMSG_RESTORE]
|
|
|
|
+ */
|
|
.freeze = i915_pm_suspend,
|
|
.freeze = i915_pm_suspend,
|
|
.freeze_late = i915_pm_suspend_late,
|
|
.freeze_late = i915_pm_suspend_late,
|
|
.thaw_early = i915_pm_resume_early,
|
|
.thaw_early = i915_pm_resume_early,
|
|
@@ -1546,6 +1566,8 @@ static const struct dev_pm_ops i915_pm_ops = {
|
|
.poweroff_late = i915_pm_suspend_late,
|
|
.poweroff_late = i915_pm_suspend_late,
|
|
.restore_early = i915_pm_resume_early,
|
|
.restore_early = i915_pm_resume_early,
|
|
.restore = i915_pm_resume,
|
|
.restore = i915_pm_resume,
|
|
|
|
+
|
|
|
|
+ /* S0ix (via runtime suspend) event handlers */
|
|
.runtime_suspend = intel_runtime_suspend,
|
|
.runtime_suspend = intel_runtime_suspend,
|
|
.runtime_resume = intel_runtime_resume,
|
|
.runtime_resume = intel_runtime_resume,
|
|
};
|
|
};
|