drm/amd/display: Use pitch when calculating size to cache in MALL
[Description] Use pitch when calculating size to cache in MALL Reviewed-by: Samson Tam <Samson.Tam@amd.com> Acked-by: Brian Chang <Brian.Chang@amd.com> Signed-off-by: Alvin Lee <Alvin.Lee2@amd.com> Tested-by: Daniel Wheeler <daniel.wheeler@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
31ec699ac5
commit
c65c71ae85
1 changed files with 1 additions and 1 deletions
|
@ -63,7 +63,7 @@ uint32_t dcn32_helper_calculate_num_ways_for_subvp(struct dc *dc, struct dc_stat
|
||||||
if (pipe->stream && pipe->plane_state && !pipe->top_pipe &&
|
if (pipe->stream && pipe->plane_state && !pipe->top_pipe &&
|
||||||
pipe->stream->mall_stream_config.type == SUBVP_PHANTOM) {
|
pipe->stream->mall_stream_config.type == SUBVP_PHANTOM) {
|
||||||
bytes_per_pixel = pipe->plane_state->format >= SURFACE_PIXEL_FORMAT_GRPH_ARGB16161616 ? 8 : 4;
|
bytes_per_pixel = pipe->plane_state->format >= SURFACE_PIXEL_FORMAT_GRPH_ARGB16161616 ? 8 : 4;
|
||||||
mall_region_pixels = pipe->stream->timing.h_addressable * pipe->stream->timing.v_addressable;
|
mall_region_pixels = pipe->plane_state->plane_size.surface_pitch * pipe->stream->timing.v_addressable;
|
||||||
|
|
||||||
// For bytes required in MALL, calculate based on number of MBlks required
|
// For bytes required in MALL, calculate based on number of MBlks required
|
||||||
num_mblks = (mall_region_pixels * bytes_per_pixel +
|
num_mblks = (mall_region_pixels * bytes_per_pixel +
|
||||||
|
|
Loading…
Add table
Reference in a new issue