aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/drm_crtc_helper.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@linux.ie>2009-04-22 04:32:56 -0400
committerDave Airlie <airlied@redhat.com>2009-04-24 00:47:00 -0400
commitc964b129425c98cb37da365e772bdbe5281f3a05 (patch)
tree91eb0fe4f4b3e0cd6cc1c34762689a694ba6e10c /drivers/gpu/drm/drm_crtc_helper.c
parente8a1344119f3787b822d110336e5dd33f6ffca70 (diff)
drm/kms: don't try to shortcut drm mode set function
We have a drm_set_config which takes a crtc/encoder/mode setup, and checks it to see if it can shortcut and just do a base setup, or whether a complete mode setting is required. Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/drm_crtc_helper.c')
-rw-r--r--drivers/gpu/drm/drm_crtc_helper.c19
1 files changed, 0 insertions, 19 deletions
diff --git a/drivers/gpu/drm/drm_crtc_helper.c b/drivers/gpu/drm/drm_crtc_helper.c
index a04639dc633d..45890447feec 100644
--- a/drivers/gpu/drm/drm_crtc_helper.c
+++ b/drivers/gpu/drm/drm_crtc_helper.c
@@ -561,7 +561,6 @@ bool drm_crtc_helper_set_mode(struct drm_crtc *crtc,
561 int saved_x, saved_y; 561 int saved_x, saved_y;
562 struct drm_encoder *encoder; 562 struct drm_encoder *encoder;
563 bool ret = true; 563 bool ret = true;
564 bool depth_changed, bpp_changed;
565 564
566 adjusted_mode = drm_mode_duplicate(dev, mode); 565 adjusted_mode = drm_mode_duplicate(dev, mode);
567 566
@@ -570,15 +569,6 @@ bool drm_crtc_helper_set_mode(struct drm_crtc *crtc,
570 if (!crtc->enabled) 569 if (!crtc->enabled)
571 return true; 570 return true;
572 571
573 if (old_fb && crtc->fb) {
574 depth_changed = (old_fb->depth != crtc->fb->depth);
575 bpp_changed = (old_fb->bits_per_pixel !=
576 crtc->fb->bits_per_pixel);
577 } else {
578 depth_changed = true;
579 bpp_changed = true;
580 }
581
582 saved_mode = crtc->mode; 572 saved_mode = crtc->mode;
583 saved_x = crtc->x; 573 saved_x = crtc->x;
584 saved_y = crtc->y; 574 saved_y = crtc->y;
@@ -590,15 +580,6 @@ bool drm_crtc_helper_set_mode(struct drm_crtc *crtc,
590 crtc->x = x; 580 crtc->x = x;
591 crtc->y = y; 581 crtc->y = y;
592 582
593 if (drm_mode_equal(&saved_mode, &crtc->mode)) {
594 if (saved_x != crtc->x || saved_y != crtc->y ||
595 depth_changed || bpp_changed) {
596 ret = !crtc_funcs->mode_set_base(crtc, crtc->x, crtc->y,
597 old_fb);
598 goto done;
599 }
600 }
601
602 /* Pass our mode to the connectors and the CRTC to give them a chance to 583 /* Pass our mode to the connectors and the CRTC to give them a chance to
603 * adjust it according to limitations or connector properties, and also 584 * adjust it according to limitations or connector properties, and also
604 * a chance to reject the mode entirely. 585 * a chance to reject the mode entirely.