aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon/r600_cs.c
diff options
context:
space:
mode:
authorRob Clark <robdclark@gmail.com>2014-07-17 23:30:05 -0400
committerDave Airlie <airlied@redhat.com>2014-07-18 00:25:23 -0400
commitb957f457fbce30cc4901dc28f2b56f2b15dfe84a (patch)
treeb0c1f3cb6e8611a727cefa7645271255e4cba133 /drivers/gpu/drm/radeon/r600_cs.c
parent7707e6535f43328e05e4729ac96eee864b90e8a4 (diff)
drm/radeon: use helpers
Signed-off-by: Rob Clark <robdclark@gmail.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/r600_cs.c')
-rw-r--r--drivers/gpu/drm/radeon/r600_cs.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/gpu/drm/radeon/r600_cs.c b/drivers/gpu/drm/radeon/r600_cs.c
index 12511bb5fd6f..c47537a1ddba 100644
--- a/drivers/gpu/drm/radeon/r600_cs.c
+++ b/drivers/gpu/drm/radeon/r600_cs.c
@@ -825,7 +825,6 @@ int r600_cs_common_vline_parse(struct radeon_cs_parser *p,
825 uint32_t *vline_start_end, 825 uint32_t *vline_start_end,
826 uint32_t *vline_status) 826 uint32_t *vline_status)
827{ 827{
828 struct drm_mode_object *obj;
829 struct drm_crtc *crtc; 828 struct drm_crtc *crtc;
830 struct radeon_crtc *radeon_crtc; 829 struct radeon_crtc *radeon_crtc;
831 struct radeon_cs_packet p3reloc, wait_reg_mem; 830 struct radeon_cs_packet p3reloc, wait_reg_mem;
@@ -887,12 +886,11 @@ int r600_cs_common_vline_parse(struct radeon_cs_parser *p,
887 crtc_id = radeon_get_ib_value(p, h_idx + 2 + 7 + 1); 886 crtc_id = radeon_get_ib_value(p, h_idx + 2 + 7 + 1);
888 reg = R600_CP_PACKET0_GET_REG(header); 887 reg = R600_CP_PACKET0_GET_REG(header);
889 888
890 obj = drm_mode_object_find(p->rdev->ddev, crtc_id, DRM_MODE_OBJECT_CRTC); 889 crtc = drm_crtc_find(p->rdev->ddev, crtc_id);
891 if (!obj) { 890 if (!crtc) {
892 DRM_ERROR("cannot find crtc %d\n", crtc_id); 891 DRM_ERROR("cannot find crtc %d\n", crtc_id);
893 return -ENOENT; 892 return -ENOENT;
894 } 893 }
895 crtc = obj_to_crtc(obj);
896 radeon_crtc = to_radeon_crtc(crtc); 894 radeon_crtc = to_radeon_crtc(crtc);
897 crtc_id = radeon_crtc->crtc_id; 895 crtc_id = radeon_crtc->crtc_id;
898 896