Commit e6b268dd authored by Joseph Gravenor's avatar Joseph Gravenor Committed by Alex Deucher

drm/amd/display: Renoir chroma viewport WA change formula

[why]
we want to increase the pte row plus 1 line if chroma viewport
height is integer multiple of the pte row height

[how]
instead of ceiling viewport height, we floor it. this allows
us to accommodate both cases: those where the chroma viewport
height is integer multiple of the pte row height and those where
it is not
Signed-off-by: default avatarJoseph Gravenor <joseph.gravenor@amd.com>
Reviewed-by: default avatarTony Cheng <Tony.Cheng@amd.com>
Acked-by: default avatarRodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 8c8048f2
...@@ -204,8 +204,8 @@ void hubp21_set_viewport( ...@@ -204,8 +204,8 @@ void hubp21_set_viewport(
PTE_ROW_HEIGHT_LINEAR, &pte_row_height); PTE_ROW_HEIGHT_LINEAR, &pte_row_height);
pte_row_height = 1 << (pte_row_height + 3); pte_row_height = 1 << (pte_row_height + 3);
pte_rows = (viewport_c->height + pte_row_height - 1) / pte_row_height; pte_rows = (viewport_c->height / pte_row_height) + 1;
patched_viewport_height = pte_rows * pte_row_height + 3; patched_viewport_height = pte_rows * pte_row_height + 1;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment