From: Michel Dänzer Date: Thu, 27 Oct 2016 04:03:23 +0000 (+0900) Subject: drm/radeon: Also call cursor_move_locked when the cursor size changes X-Git-Tag: v4.1.38~37 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7198dbbaa242e151abc94c67bc926b302bb4e799;p=platform%2Fkernel%2Flinux-exynos.git drm/radeon: Also call cursor_move_locked when the cursor size changes [ Upstream commit dcab0fa64e300afa18f39cd98d05e0950f652adf ] The cursor size also affects the register programming. Cc: stable@vger.kernel.org Signed-off-by: Michel Dänzer Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher Signed-off-by: Sasha Levin --- diff --git a/drivers/gpu/drm/radeon/radeon_cursor.c b/drivers/gpu/drm/radeon/radeon_cursor.c index fa661744a1f5..c28e3e1e5344 100644 --- a/drivers/gpu/drm/radeon/radeon_cursor.c +++ b/drivers/gpu/drm/radeon/radeon_cursor.c @@ -306,12 +306,11 @@ int radeon_crtc_cursor_set2(struct drm_crtc *crtc, return ret; } - radeon_crtc->cursor_width = width; - radeon_crtc->cursor_height = height; - radeon_lock_cursor(crtc, true); - if (hot_x != radeon_crtc->cursor_hot_x || + if (width != radeon_crtc->cursor_width || + height != radeon_crtc->cursor_height || + hot_x != radeon_crtc->cursor_hot_x || hot_y != radeon_crtc->cursor_hot_y) { int x, y; @@ -320,6 +319,8 @@ int radeon_crtc_cursor_set2(struct drm_crtc *crtc, radeon_cursor_move_locked(crtc, x, y); + radeon_crtc->cursor_width = width; + radeon_crtc->cursor_height = height; radeon_crtc->cursor_hot_x = hot_x; radeon_crtc->cursor_hot_y = hot_y; }