From 2317d32c6785cc67b57046d183c88d1afa2f7785 Mon Sep 17 00:00:00 2001 From: Daniel Vetter Date: Fri, 9 Aug 2013 11:36:09 +0200 Subject: [PATCH] more debug output for pch pll sharing failures --- drivers/gpu/drm/i915/intel_display.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index a0914db..f860992 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -49,6 +49,10 @@ static void i9xx_crtc_clock_get(struct intel_crtc *crtc, struct intel_crtc_config *pipe_config); static void ironlake_crtc_clock_get(struct intel_crtc *crtc, struct intel_crtc_config *pipe_config); +static void intel_dump_pipe_config(struct intel_crtc *crtc, + struct intel_crtc_config *pipe_config, + const char *context); + typedef struct { int min, max; @@ -5798,6 +5802,8 @@ static int ironlake_crtc_mode_set(struct drm_crtc *crtc, if (pll == NULL) { DRM_DEBUG_DRIVER("failed to find PLL for pipe %c\n", pipe_name(pipe)); + intel_dump_pipe_config(intel_crtc, &intel_crtc->config, + "[pch pll fail]"); return -EINVAL; } } else @@ -7990,6 +7996,8 @@ static void intel_dump_pipe_config(struct intel_crtc *crtc, struct intel_crtc_config *pipe_config, const char *context) { + struct drm_i915_private *dev_priv = crtc->base.dev->dev_private; + DRM_DEBUG_KMS("[CRTC:%d]%s config for pipe %c\n", crtc->base.base.id, context, pipe_name(crtc->pipe)); @@ -8014,6 +8022,14 @@ static void intel_dump_pipe_config(struct intel_crtc *crtc, pipe_config->pch_pfit.pos, pipe_config->pch_pfit.size); DRM_DEBUG_KMS("ips: %i\n", pipe_config->ips_enabled); + DRM_DEBUG_KMS("shared dpll: %s\n", pipe_config->shared_dpll >= 0 ? + dev_priv->shared_dplls[pipe_config->shared_dpll].name : + "(private dpll)"); + DRM_DEBUG_KMS("dpll state: dpll 0x%08x, dpll_md 0x%08x, fp0 0x%08x, fp1 0x%08x\n", + pipe_config->dpll_hw_state.dpll, + pipe_config->dpll_hw_state.dpll_md, + pipe_config->dpll_hw_state.fp0, + pipe_config->dpll_hw_state.fp1); } static bool check_encoder_cloning(struct drm_crtc *crtc) -- 1.8.3.2