aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2012-10-31 17:52:27 -0400
committerDaniel Vetter <daniel.vetter@ffwll.ch>2012-11-11 17:51:29 -0500
commit7fcb83cde02da2f0c7d7eb8ba2c51df24495c0a8 (patch)
treed4a694c006581aa997a0e344a22b6084c72e02e4 /drivers
parent270b30420c5e0d5f779aa76882367f9265c5aa7d (diff)
drm/i915: check whether the pch is the soulmate of the cpu
We don't really support fancy north display/pch combinations, so put a big yelling WARN_ON in there. It /should/ be impossible, but alas, the rumours don't stop (mostly due to really early silicon sometimes using older PCHs). v2: Fixup the logic fumble noticed by Paulo Zanoni. I should actually try to test run the patch next time around ... Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/gpu/drm/i915/i915_drv.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915_drv.c
index 42388533708f..4be4841854b0 100644
--- a/drivers/gpu/drm/i915/i915_drv.c
+++ b/drivers/gpu/drm/i915/i915_drv.c
@@ -416,19 +416,23 @@ void intel_detect_pch(struct drm_device *dev)
416 dev_priv->pch_type = PCH_IBX; 416 dev_priv->pch_type = PCH_IBX;
417 dev_priv->num_pch_pll = 2; 417 dev_priv->num_pch_pll = 2;
418 DRM_DEBUG_KMS("Found Ibex Peak PCH\n"); 418 DRM_DEBUG_KMS("Found Ibex Peak PCH\n");
419 WARN_ON(!IS_GEN5(dev));
419 } else if (id == INTEL_PCH_CPT_DEVICE_ID_TYPE) { 420 } else if (id == INTEL_PCH_CPT_DEVICE_ID_TYPE) {
420 dev_priv->pch_type = PCH_CPT; 421 dev_priv->pch_type = PCH_CPT;
421 dev_priv->num_pch_pll = 2; 422 dev_priv->num_pch_pll = 2;
422 DRM_DEBUG_KMS("Found CougarPoint PCH\n"); 423 DRM_DEBUG_KMS("Found CougarPoint PCH\n");
424 WARN_ON(!(IS_GEN6(dev) || IS_IVYBRIDGE(dev)));
423 } else if (id == INTEL_PCH_PPT_DEVICE_ID_TYPE) { 425 } else if (id == INTEL_PCH_PPT_DEVICE_ID_TYPE) {
424 /* PantherPoint is CPT compatible */ 426 /* PantherPoint is CPT compatible */
425 dev_priv->pch_type = PCH_CPT; 427 dev_priv->pch_type = PCH_CPT;
426 dev_priv->num_pch_pll = 2; 428 dev_priv->num_pch_pll = 2;
427 DRM_DEBUG_KMS("Found PatherPoint PCH\n"); 429 DRM_DEBUG_KMS("Found PatherPoint PCH\n");
430 WARN_ON(!(IS_GEN6(dev) || IS_IVYBRIDGE(dev)));
428 } else if (id == INTEL_PCH_LPT_DEVICE_ID_TYPE) { 431 } else if (id == INTEL_PCH_LPT_DEVICE_ID_TYPE) {
429 dev_priv->pch_type = PCH_LPT; 432 dev_priv->pch_type = PCH_LPT;
430 dev_priv->num_pch_pll = 0; 433 dev_priv->num_pch_pll = 0;
431 DRM_DEBUG_KMS("Found LynxPoint PCH\n"); 434 DRM_DEBUG_KMS("Found LynxPoint PCH\n");
435 WARN_ON(!IS_HASWELL(dev));
432 } 436 }
433 BUG_ON(dev_priv->num_pch_pll > I915_NUM_PLLS); 437 BUG_ON(dev_priv->num_pch_pll > I915_NUM_PLLS);
434 } 438 }