diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2013-05-03 12:36:25 -0400 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2013-05-21 06:15:58 -0400 |
commit | 2d05eae1c92f93ace0fc6f282c55527d293297dd (patch) | |
tree | 8297d73a3c446d29d6bf338a7eabe2880b114345 /drivers/gpu/drm/i915/intel_display.c | |
parent | 1c98b4871cca4b7ce07e19f92f934d47cf7210b0 (diff) |
drm/i915: Propagate errors back from fb set-base
Along the modesetting short cut where we skip trying to do a full
modeset and instead simply update the framebuffer base registers, we
failed to handle any errors reported.
This regression has been introduced in
commit 94352cf9a5328bb1a44288e6c2c1276695f8a356
Author: Daniel Vetter <daniel.vetter@ffwll.ch>
Date: Thu Jul 5 22:51:56 2012 +0200
drm/i915: push crtc->fb update into pipe_set_base
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
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.c | 25 |
1 files changed, 10 insertions, 15 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index efe829919755..300942a7d144 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c | |||
@@ -8332,11 +8332,6 @@ static int intel_crtc_set_config(struct drm_mode_set *set) | |||
8332 | 8332 | ||
8333 | ret = intel_set_mode(set->crtc, set->mode, | 8333 | ret = intel_set_mode(set->crtc, set->mode, |
8334 | set->x, set->y, set->fb); | 8334 | set->x, set->y, set->fb); |
8335 | if (ret) { | ||
8336 | DRM_ERROR("failed to set mode on [CRTC:%d], err = %d\n", | ||
8337 | set->crtc->base.id, ret); | ||
8338 | goto fail; | ||
8339 | } | ||
8340 | } else if (config->fb_changed) { | 8335 | } else if (config->fb_changed) { |
8341 | intel_crtc_wait_for_pending_flips(set->crtc); | 8336 | intel_crtc_wait_for_pending_flips(set->crtc); |
8342 | 8337 | ||
@@ -8344,18 +8339,18 @@ static int intel_crtc_set_config(struct drm_mode_set *set) | |||
8344 | set->x, set->y, set->fb); | 8339 | set->x, set->y, set->fb); |
8345 | } | 8340 | } |
8346 | 8341 | ||
8347 | intel_set_config_free(config); | 8342 | if (ret) { |
8348 | 8343 | DRM_ERROR("failed to set mode on [CRTC:%d], err = %d\n", | |
8349 | return 0; | 8344 | set->crtc->base.id, ret); |
8350 | |||
8351 | fail: | 8345 | fail: |
8352 | intel_set_config_restore_state(dev, config); | 8346 | intel_set_config_restore_state(dev, config); |
8353 | 8347 | ||
8354 | /* Try to restore the config */ | 8348 | /* Try to restore the config */ |
8355 | if (config->mode_changed && | 8349 | if (config->mode_changed && |
8356 | intel_set_mode(save_set.crtc, save_set.mode, | 8350 | intel_set_mode(save_set.crtc, save_set.mode, |
8357 | save_set.x, save_set.y, save_set.fb)) | 8351 | save_set.x, save_set.y, save_set.fb)) |
8358 | DRM_ERROR("failed to restore config after modeset failure\n"); | 8352 | DRM_ERROR("failed to restore config after modeset failure\n"); |
8353 | } | ||
8359 | 8354 | ||
8360 | out_config: | 8355 | out_config: |
8361 | intel_set_config_free(config); | 8356 | intel_set_config_free(config); |