aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesse Barnes <jbarnes@virtuousgeek.org>2011-07-19 18:38:56 -0400
committerKeith Packard <keithp@keithp.com>2011-07-21 23:18:24 -0400
commita5071c2fd91f320bc40952df59517053a7346fa9 (patch)
tree2ca6e47bbf137d518753d25596373f28aaff7405
parent28a4a163b561c39ac0c798d420e0927f29e9d4c8 (diff)
drm/i915: provide more error output when mode sets fail
If a mode set fails we may get a message from drm_crtc_helper if we're lucky, but it won't tell us anything about *why* we failed to set a mode. So add a few DRM_ERRORs for the cases that shouldn't happen so we can debug things more easily. Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org> Signed-off-by: Keith Packard <keithp@keithp.com>
-rw-r--r--drivers/gpu/drm/i915/intel_display.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index b5b15bda71d9..261ffe47a5d2 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -2096,7 +2096,7 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, int y,
2096 2096
2097 /* no fb bound */ 2097 /* no fb bound */
2098 if (!crtc->fb) { 2098 if (!crtc->fb) {
2099 DRM_DEBUG_KMS("No FB bound\n"); 2099 DRM_ERROR("No FB bound\n");
2100 return 0; 2100 return 0;
2101 } 2101 }
2102 2102
@@ -2105,6 +2105,7 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, int y,
2105 case 1: 2105 case 1:
2106 break; 2106 break;
2107 default: 2107 default:
2108 DRM_ERROR("no plane for crtc\n");
2108 return -EINVAL; 2109 return -EINVAL;
2109 } 2110 }
2110 2111
@@ -2114,6 +2115,7 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, int y,
2114 NULL); 2115 NULL);
2115 if (ret != 0) { 2116 if (ret != 0) {
2116 mutex_unlock(&dev->struct_mutex); 2117 mutex_unlock(&dev->struct_mutex);
2118 DRM_ERROR("pin & fence failed\n");
2117 return ret; 2119 return ret;
2118 } 2120 }
2119 2121
@@ -2142,6 +2144,7 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, int y,
2142 if (ret) { 2144 if (ret) {
2143 i915_gem_object_unpin(to_intel_framebuffer(crtc->fb)->obj); 2145 i915_gem_object_unpin(to_intel_framebuffer(crtc->fb)->obj);
2144 mutex_unlock(&dev->struct_mutex); 2146 mutex_unlock(&dev->struct_mutex);
2147 DRM_ERROR("failed to update base address\n");
2145 return ret; 2148 return ret;
2146 } 2149 }
2147 2150