Commit 35d13315 authored by Martin Tsai's avatar Martin Tsai Committed by Alex Deucher
Browse files

drm/amd/display: correct the condition in setting cursor not visible beyond left edge

parent 86993018
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -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,
+1 −1
Original line number Diff line number Diff line
@@ -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)