In the KMS case, enter/leavevt won't fix up the interrupt handler for
us, so we need to do it at suspend/resume time. Make sure we don't fail
the resume if the chip is hung either.
Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
i915_save_state(dev);
/* If KMS is active, we do the leavevt stuff here */
- if (drm_core_check_feature(dev, DRIVER_MODESET) && i915_gem_idle(dev)) {
- dev_err(&dev->pdev->dev, "GEM idle failed, aborting suspend\n");
- return -EBUSY;
+ if (drm_core_check_feature(dev, DRIVER_MODESET)) {
+ if (i915_gem_idle(dev))
+ dev_err(&dev->pdev->dev,
+ "GEM idle failed, resume may fail\n");
+ drm_irq_uninstall(dev);
}
intel_opregion_free(dev);
if (ret != 0)
ret = -1;
mutex_unlock(&dev->struct_mutex);
+
+ drm_irq_install(dev);
}
return ret;