aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon/radeon_display.c
diff options
context:
space:
mode:
authorMatt Roper <matthew.d.roper@intel.com>2014-04-01 18:22:40 -0400
committerRob Clark <robdclark@gmail.com>2014-04-01 20:18:28 -0400
commitf4510a2752b75ad5847b7935b68c233cab497f97 (patch)
tree0104efe442302d22b705f34605070a009cc633c9 /drivers/gpu/drm/radeon/radeon_display.c
parent2d82d188b2cb11b6b221eb84dda2344ef3cd1bb4 (diff)
drm: Replace crtc fb with primary plane fb (v3)
Now that CRTC's have a primary plane, there's no need to track the framebuffer in the CRTC. Replace all references to the CRTC fb with the primary plane's fb. This patch was generated by the Coccinelle semantic patching tool using the following rules: @@ struct drm_crtc C; @@ - (C).fb + C.primary->fb @@ struct drm_crtc *C; @@ - (C)->fb + C->primary->fb v3: Generate patch via coccinelle. Actual removal of crtc->fb has been moved to a subsequent patch. v2: Fixup several lingering crtc->fb instances that were missed in the first patch iteration. [Rob Clark] Signed-off-by: Matt Roper <matthew.d.roper@intel.com> Reviewed-by: Rob Clark <robdclark@gmail.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_display.c')
-rw-r--r--drivers/gpu/drm/radeon/radeon_display.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_display.c b/drivers/gpu/drm/radeon/radeon_display.c
index fbd8b930f2be..5701fbb36b3c 100644
--- a/drivers/gpu/drm/radeon/radeon_display.c
+++ b/drivers/gpu/drm/radeon/radeon_display.c
@@ -369,7 +369,7 @@ static int radeon_crtc_page_flip(struct drm_crtc *crtc,
369 work->event = event; 369 work->event = event;
370 work->rdev = rdev; 370 work->rdev = rdev;
371 work->crtc_id = radeon_crtc->crtc_id; 371 work->crtc_id = radeon_crtc->crtc_id;
372 old_radeon_fb = to_radeon_framebuffer(crtc->fb); 372 old_radeon_fb = to_radeon_framebuffer(crtc->primary->fb);
373 new_radeon_fb = to_radeon_framebuffer(fb); 373 new_radeon_fb = to_radeon_framebuffer(fb);
374 /* schedule unpin of the old buffer */ 374 /* schedule unpin of the old buffer */
375 obj = old_radeon_fb->obj; 375 obj = old_radeon_fb->obj;
@@ -460,7 +460,7 @@ static int radeon_crtc_page_flip(struct drm_crtc *crtc,
460 spin_unlock_irqrestore(&dev->event_lock, flags); 460 spin_unlock_irqrestore(&dev->event_lock, flags);
461 461
462 /* update crtc fb */ 462 /* update crtc fb */
463 crtc->fb = fb; 463 crtc->primary->fb = fb;
464 464
465 r = drm_vblank_get(dev, radeon_crtc->crtc_id); 465 r = drm_vblank_get(dev, radeon_crtc->crtc_id);
466 if (r) { 466 if (r) {