mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-22 20:24:29 +07:00
drm/amd/display: correct the condition in setting cursor not visible beyond left edge
Signed-off-by: Martin Tsai <martin.tsai@amd.com> Reviewed-by: Tony Cheng <Tony.Cheng@amd.com> Acked-by: Harry Wentland <harry.wentland@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
86993018d7
commit
35d1331595
@ -416,7 +416,7 @@ void dpp1_set_cursor_position(
|
||||
if (src_x_offset >= (int)param->viewport_width)
|
||||
cur_en = 0; /* not visible beyond right edge*/
|
||||
|
||||
if (src_x_offset + (int)width < 0)
|
||||
if (src_x_offset + (int)width <= 0)
|
||||
cur_en = 0; /* not visible beyond left edge*/
|
||||
|
||||
REG_UPDATE(CURSOR0_CONTROL,
|
||||
|
@ -897,7 +897,7 @@ void hubp1_cursor_set_position(
|
||||
if (src_x_offset >= (int)param->viewport_width)
|
||||
cur_en = 0; /* not visible beyond right edge*/
|
||||
|
||||
if (src_x_offset + (int)hubp->curs_attr.width < 0)
|
||||
if (src_x_offset + (int)hubp->curs_attr.width <= 0)
|
||||
cur_en = 0; /* not visible beyond left edge*/
|
||||
|
||||
if (cur_en && REG_READ(CURSOR_SURFACE_ADDRESS) == 0)
|
||||
|
Loading…
Reference in New Issue
Block a user