aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/intel_display.c
diff options
context:
space:
mode:
authorVille Syrjälä <ville.syrjala@linux.intel.com>2013-04-17 10:48:49 -0400
committerDaniel Vetter <daniel.vetter@ffwll.ch>2013-04-18 03:55:49 -0400
commit84f44ce795b3da9a08dc2041ecd60550d34c123e (patch)
tree9b762d203116a0e3fad906ba185bcbb70b92e828 /drivers/gpu/drm/i915/intel_display.c
parentcfc33bf75bfbf8f95bffe040ee1a5ab1cda8c34c (diff)
drm/i915: Print plane, pipe, port names as alphabetical insted of decimal
Alway use the alphabetical names in debug/error messages for planes, pipes and ports, instead of using decimal numbers occasionally. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_display.c')
-rw-r--r--drivers/gpu/drm/i915/intel_display.c42
1 files changed, 21 insertions, 21 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index 462c81a871ab..e472488394ae 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -2101,7 +2101,7 @@ static int i9xx_update_plane(struct drm_crtc *crtc, struct drm_framebuffer *fb,
2101 case 1: 2101 case 1:
2102 break; 2102 break;
2103 default: 2103 default:
2104 DRM_ERROR("Can't update plane %d in SAREA\n", plane); 2104 DRM_ERROR("Can't update plane %c in SAREA\n", plane_name(plane));
2105 return -EINVAL; 2105 return -EINVAL;
2106 } 2106 }
2107 2107
@@ -2198,7 +2198,7 @@ static int ironlake_update_plane(struct drm_crtc *crtc,
2198 case 2: 2198 case 2:
2199 break; 2199 break;
2200 default: 2200 default:
2201 DRM_ERROR("Can't update plane %d in SAREA\n", plane); 2201 DRM_ERROR("Can't update plane %c in SAREA\n", plane_name(plane));
2202 return -EINVAL; 2202 return -EINVAL;
2203 } 2203 }
2204 2204
@@ -2389,9 +2389,9 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, int y,
2389 } 2389 }
2390 2390
2391 if (intel_crtc->plane > INTEL_INFO(dev)->num_pipes) { 2391 if (intel_crtc->plane > INTEL_INFO(dev)->num_pipes) {
2392 DRM_ERROR("no plane for crtc: plane %d, num_pipes %d\n", 2392 DRM_ERROR("no plane for crtc: plane %c, num_pipes %d\n",
2393 intel_crtc->plane, 2393 plane_name(intel_crtc->plane),
2394 INTEL_INFO(dev)->num_pipes); 2394 INTEL_INFO(dev)->num_pipes);
2395 return -EINVAL; 2395 return -EINVAL;
2396 } 2396 }
2397 2397
@@ -3299,7 +3299,7 @@ static struct intel_pch_pll *intel_get_pch_pll(struct intel_crtc *intel_crtc, u3
3299found: 3299found:
3300 intel_crtc->pch_pll = pll; 3300 intel_crtc->pch_pll = pll;
3301 pll->refcount++; 3301 pll->refcount++;
3302 DRM_DEBUG_DRIVER("using pll %d for pipe %d\n", i, intel_crtc->pipe); 3302 DRM_DEBUG_DRIVER("using pll %d for pipe %c\n", i, pipe_name(intel_crtc->pipe));
3303prepare: /* separate function? */ 3303prepare: /* separate function? */
3304 DRM_DEBUG_DRIVER("switching PLL %x off\n", pll->pll_reg); 3304 DRM_DEBUG_DRIVER("switching PLL %x off\n", pll->pll_reg);
3305 3305
@@ -3324,7 +3324,7 @@ void intel_cpt_verify_modeset(struct drm_device *dev, int pipe)
3324 udelay(500); 3324 udelay(500);
3325 if (wait_for(I915_READ(dslreg) != temp, 5)) { 3325 if (wait_for(I915_READ(dslreg) != temp, 5)) {
3326 if (wait_for(I915_READ(dslreg) != temp, 5)) 3326 if (wait_for(I915_READ(dslreg) != temp, 5))
3327 DRM_ERROR("mode set failed: pipe %d stuck\n", pipe); 3327 DRM_ERROR("mode set failed: pipe %c stuck\n", pipe_name(pipe));
3328 } 3328 }
3329} 3329}
3330 3330
@@ -5344,11 +5344,11 @@ static bool ironlake_check_fdi_lanes(struct intel_crtc *intel_crtc)
5344 struct intel_crtc *pipe_B_crtc = 5344 struct intel_crtc *pipe_B_crtc =
5345 to_intel_crtc(dev_priv->pipe_to_crtc_mapping[PIPE_B]); 5345 to_intel_crtc(dev_priv->pipe_to_crtc_mapping[PIPE_B]);
5346 5346
5347 DRM_DEBUG_KMS("checking fdi config on pipe %i, lanes %i\n", 5347 DRM_DEBUG_KMS("checking fdi config on pipe %c, lanes %i\n",
5348 intel_crtc->pipe, intel_crtc->fdi_lanes); 5348 pipe_name(intel_crtc->pipe), intel_crtc->fdi_lanes);
5349 if (intel_crtc->fdi_lanes > 4) { 5349 if (intel_crtc->fdi_lanes > 4) {
5350 DRM_DEBUG_KMS("invalid fdi lane config on pipe %i: %i lanes\n", 5350 DRM_DEBUG_KMS("invalid fdi lane config on pipe %c: %i lanes\n",
5351 intel_crtc->pipe, intel_crtc->fdi_lanes); 5351 pipe_name(intel_crtc->pipe), intel_crtc->fdi_lanes);
5352 /* Clamp lanes to avoid programming the hw with bogus values. */ 5352 /* Clamp lanes to avoid programming the hw with bogus values. */
5353 intel_crtc->fdi_lanes = 4; 5353 intel_crtc->fdi_lanes = 4;
5354 5354
@@ -5364,8 +5364,8 @@ static bool ironlake_check_fdi_lanes(struct intel_crtc *intel_crtc)
5364 case PIPE_B: 5364 case PIPE_B:
5365 if (dev_priv->pipe_to_crtc_mapping[PIPE_C]->enabled && 5365 if (dev_priv->pipe_to_crtc_mapping[PIPE_C]->enabled &&
5366 intel_crtc->fdi_lanes > 2) { 5366 intel_crtc->fdi_lanes > 2) {
5367 DRM_DEBUG_KMS("invalid shared fdi lane config on pipe %i: %i lanes\n", 5367 DRM_DEBUG_KMS("invalid shared fdi lane config on pipe %c: %i lanes\n",
5368 intel_crtc->pipe, intel_crtc->fdi_lanes); 5368 pipe_name(intel_crtc->pipe), intel_crtc->fdi_lanes);
5369 /* Clamp lanes to avoid programming the hw with bogus values. */ 5369 /* Clamp lanes to avoid programming the hw with bogus values. */
5370 intel_crtc->fdi_lanes = 2; 5370 intel_crtc->fdi_lanes = 2;
5371 5371
@@ -5381,8 +5381,8 @@ static bool ironlake_check_fdi_lanes(struct intel_crtc *intel_crtc)
5381 case PIPE_C: 5381 case PIPE_C:
5382 if (!pipe_B_crtc->base.enabled || pipe_B_crtc->fdi_lanes <= 2) { 5382 if (!pipe_B_crtc->base.enabled || pipe_B_crtc->fdi_lanes <= 2) {
5383 if (intel_crtc->fdi_lanes > 2) { 5383 if (intel_crtc->fdi_lanes > 2) {
5384 DRM_DEBUG_KMS("invalid shared fdi lane config on pipe %i: %i lanes\n", 5384 DRM_DEBUG_KMS("invalid shared fdi lane config on pipe %c: %i lanes\n",
5385 intel_crtc->pipe, intel_crtc->fdi_lanes); 5385 pipe_name(intel_crtc->pipe), intel_crtc->fdi_lanes);
5386 /* Clamp lanes to avoid programming the hw with bogus values. */ 5386 /* Clamp lanes to avoid programming the hw with bogus values. */
5387 intel_crtc->fdi_lanes = 2; 5387 intel_crtc->fdi_lanes = 2;
5388 5388
@@ -5647,7 +5647,7 @@ static int ironlake_crtc_mode_set(struct drm_crtc *crtc,
5647 dpll = ironlake_compute_dpll(intel_crtc, &clock, &fp, &reduced_clock, 5647 dpll = ironlake_compute_dpll(intel_crtc, &clock, &fp, &reduced_clock,
5648 has_reduced_clock ? &fp2 : NULL); 5648 has_reduced_clock ? &fp2 : NULL);
5649 5649
5650 DRM_DEBUG_KMS("Mode for pipe %d:\n", pipe); 5650 DRM_DEBUG_KMS("Mode for pipe %c:\n", pipe_name(pipe));
5651 drm_mode_debug_printmodeline(mode); 5651 drm_mode_debug_printmodeline(mode);
5652 5652
5653 /* CPU eDP is the only output that doesn't need a PCH PLL of its own. */ 5653 /* CPU eDP is the only output that doesn't need a PCH PLL of its own. */
@@ -5656,8 +5656,8 @@ static int ironlake_crtc_mode_set(struct drm_crtc *crtc,
5656 5656
5657 pll = intel_get_pch_pll(intel_crtc, dpll, fp); 5657 pll = intel_get_pch_pll(intel_crtc, dpll, fp);
5658 if (pll == NULL) { 5658 if (pll == NULL) {
5659 DRM_DEBUG_DRIVER("failed to find PLL for pipe %d\n", 5659 DRM_DEBUG_DRIVER("failed to find PLL for pipe %c\n",
5660 pipe); 5660 pipe_name(pipe));
5661 return -EINVAL; 5661 return -EINVAL;
5662 } 5662 }
5663 } else 5663 } else
@@ -5821,7 +5821,7 @@ static int haswell_crtc_mode_set(struct drm_crtc *crtc,
5821 /* determine panel color depth */ 5821 /* determine panel color depth */
5822 dither = intel_crtc->config.dither; 5822 dither = intel_crtc->config.dither;
5823 5823
5824 DRM_DEBUG_KMS("Mode for pipe %d:\n", pipe); 5824 DRM_DEBUG_KMS("Mode for pipe %c:\n", pipe_name(pipe));
5825 drm_mode_debug_printmodeline(mode); 5825 drm_mode_debug_printmodeline(mode);
5826 5826
5827 if (intel_crtc->config.has_dp_encoder) 5827 if (intel_crtc->config.has_dp_encoder)
@@ -9051,8 +9051,8 @@ void intel_modeset_init(struct drm_device *dev)
9051 for (j = 0; j < dev_priv->num_plane; j++) { 9051 for (j = 0; j < dev_priv->num_plane; j++) {
9052 ret = intel_plane_init(dev, i, j); 9052 ret = intel_plane_init(dev, i, j);
9053 if (ret) 9053 if (ret)
9054 DRM_DEBUG_KMS("pipe %d plane %d init failed: %d\n", 9054 DRM_DEBUG_KMS("pipe %c plane %d init failed: %d\n",
9055 i, j, ret); 9055 pipe_name(i), j, ret);
9056 } 9056 }
9057 } 9057 }
9058 9058