aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlvin Lee <alvin.lee2@amd.com>2024-04-16 14:42:18 -0400
committerAlex Deucher <alexander.deucher@amd.com>2024-04-30 09:56:38 -0400
commit984debc133efa05e62f5aa1a7a1dd8ca0ef041f4 (patch)
tree482c340d5d9649b2284cbae5fda2841ec48c180c
parentf9c7818c9d653e40dbd3c7e9c857e5b00dfca622 (diff)
drm/amd/display: Assign linear_pitch_alignment even for VM
[Description] Assign linear_pitch_alignment so we don't cause a divide by 0 error in VM environments Reviewed-by: Sohaib Nadeem <sohaib.nadeem@amd.com> Acked-by: Wayne Lin <wayne.lin@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>
-rw-r--r--drivers/gpu/drm/amd/display/dc/core/dc.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/core/dc.c b/drivers/gpu/drm/amd/display/dc/core/dc.c
index 0a91083a3e06..a8eb286ee4ff 100644
--- a/drivers/gpu/drm/amd/display/dc/core/dc.c
+++ b/drivers/gpu/drm/amd/display/dc/core/dc.c
@@ -1425,6 +1425,7 @@ struct dc *dc_create(const struct dc_init_data *init_params)
return NULL;
if (init_params->dce_environment == DCE_ENV_VIRTUAL_HW) {
+ dc->caps.linear_pitch_alignment = 64;
if (!dc_construct_ctx(dc, init_params))
goto destruct_dc;
} else {