drm/i915/bdw: Add BDW PCH check first
authorBen Widawsky <benjamin.widawsky@intel.com>
Fri, 8 Nov 2013 05:40:41 +0000 (21:40 -0800)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Fri, 8 Nov 2013 17:10:09 +0000 (18:10 +0100)
Early platforms use the same PCH as HSW, and to avoid triggering the
!ULT, and !HSW warnings, simply put it first in the search.

Signed-off-by: Ben Widawsky <ben@bwidawsk.net>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_drv.c

index bbea429ec4b52b75c743db393bd97b8c6d16c782..989be12cdd6e962e625b8376734f101ace947d1c 100644 (file)
@@ -448,17 +448,17 @@ void intel_detect_pch(struct drm_device *dev)
                                DRM_DEBUG_KMS("Found LynxPoint PCH\n");
                                WARN_ON(!IS_HASWELL(dev));
                                WARN_ON(IS_ULT(dev));
-                       } else if (id == INTEL_PCH_LPT_LP_DEVICE_ID_TYPE) {
-                               dev_priv->pch_type = PCH_LPT;
-                               DRM_DEBUG_KMS("Found LynxPoint LP PCH\n");
-                               WARN_ON(!IS_HASWELL(dev));
-                               WARN_ON(!IS_ULT(dev));
                        } else if (IS_BROADWELL(dev)) {
                                dev_priv->pch_type = PCH_LPT;
                                dev_priv->pch_id =
                                        INTEL_PCH_LPT_LP_DEVICE_ID_TYPE;
                                DRM_DEBUG_KMS("This is Broadwell, assuming "
                                              "LynxPoint LP PCH\n");
+                       } else if (id == INTEL_PCH_LPT_LP_DEVICE_ID_TYPE) {
+                               dev_priv->pch_type = PCH_LPT;
+                               DRM_DEBUG_KMS("Found LynxPoint LP PCH\n");
+                               WARN_ON(!IS_HASWELL(dev));
+                               WARN_ON(!IS_ULT(dev));
                        } else {
                                goto check_next;
                        }