]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - drivers/gpu/drm/i915/i915_drv.c
Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux
[karo-tx-linux.git] / drivers / gpu / drm / i915 / i915_drv.c
index 1d887459e37fd717992ddbfb52228d8550e55a09..ab64d68388f232b543bf19c1726b44c7cd329eaa 100644 (file)
@@ -662,15 +662,18 @@ static int i915_drm_suspend_late(struct drm_device *drm_dev, bool hibernation)
 
        pci_disable_device(drm_dev->pdev);
        /*
-        * During hibernation on some GEN4 platforms the BIOS may try to access
+        * During hibernation on some platforms the BIOS may try to access
         * the device even though it's already in D3 and hang the machine. So
         * leave the device in D0 on those platforms and hope the BIOS will
-        * power down the device properly. Platforms where this was seen:
-        * Lenovo Thinkpad X301, X61s
+        * power down the device properly. The issue was seen on multiple old
+        * GENs with different BIOS vendors, so having an explicit blacklist
+        * is inpractical; apply the workaround on everything pre GEN6. The
+        * platforms where the issue was seen:
+        * Lenovo Thinkpad X301, X61s, X60, T60, X41
+        * Fujitsu FSC S7110
+        * Acer Aspire 1830T
         */
-       if (!(hibernation &&
-             drm_dev->pdev->subsystem_vendor == PCI_VENDOR_ID_LENOVO &&
-             INTEL_INFO(dev_priv)->gen == 4))
+       if (!(hibernation && INTEL_INFO(dev_priv)->gen < 6))
                pci_set_power_state(drm_dev->pdev, PCI_D3hot);
 
        return 0;
@@ -727,7 +730,7 @@ static int i915_drm_resume(struct drm_device *dev)
        mutex_lock(&dev->struct_mutex);
        if (i915_gem_init_hw(dev)) {
                DRM_ERROR("failed to re-initialize GPU, declaring wedged!\n");
-               atomic_set_mask(I915_WEDGED, &dev_priv->gpu_error.reset_counter);
+                       atomic_or(I915_WEDGED, &dev_priv->gpu_error.reset_counter);
        }
        mutex_unlock(&dev->struct_mutex);