From 72cf231d10d7940b92737b9eb6b9e6b01e9299de Mon Sep 17 00:00:00 2001 From: jsg Date: Wed, 15 Feb 2023 10:26:50 +0000 Subject: [PATCH] drm/amd/display: fix cursor offset on rotation 180 From Melissa Wen 5af27a53a881ed49e071875c10760b0fc13996a1 in linux-6.1.y/6.1.12 49d0555976f0972af68397ed996375c135b38ba7 in mainline linux --- sys/dev/pci/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/pci/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c b/sys/dev/pci/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c index c06538c37a1..55d63d860ef 100644 --- a/sys/dev/pci/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c +++ b/sys/dev/pci/drm/amd/display/dc/dcn10/dcn10_hw_sequencer.c @@ -3612,7 +3612,7 @@ void dcn10_set_cursor_position(struct pipe_ctx *pipe_ctx) (int)hubp->curs_attr.width || pos_cpy.x <= (int)hubp->curs_attr.width + pipe_ctx->plane_state->src_rect.x) { - pos_cpy.x = temp_x + viewport_width; + pos_cpy.x = 2 * viewport_width - temp_x; } } } else { -- 2.20.1