diff options
author | jsg <jsg@openbsd.org> | 2020-06-22 10:05:32 +0000 |
---|---|---|
committer | jsg <jsg@openbsd.org> | 2020-06-22 10:05:32 +0000 |
commit | 89a24421a16746736edd3067133ca8850964461f (patch) | |
tree | 78a02150ad3257ba338997ea07298c70a13b8eee | |
parent | drm/amd/display: dmcu wait loop calculation is incorrect in RV (diff) | |
download | wireguard-openbsd-89a24421a16746736edd3067133ca8850964461f.tar.xz wireguard-openbsd-89a24421a16746736edd3067133ca8850964461f.zip |
drm/amd/display: Do not disable pipe split if mode is not supported
From Sung Lee
dbf0a8fce6a9c867c315a400176f9f0e3a963d1e in linux 5.7.y/5.7.5
1dfedb39d38f813357885e19badd1971c17f79a7 in mainline linux
-rw-r--r-- | sys/dev/pci/drm/amd/display/dc/dcn20/dcn20_resource.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/sys/dev/pci/drm/amd/display/dc/dcn20/dcn20_resource.c b/sys/dev/pci/drm/amd/display/dc/dcn20/dcn20_resource.c index e4348e3b638..2719cdecc1c 100644 --- a/sys/dev/pci/drm/amd/display/dc/dcn20/dcn20_resource.c +++ b/sys/dev/pci/drm/amd/display/dc/dcn20/dcn20_resource.c @@ -2597,19 +2597,24 @@ int dcn20_validate_apply_pipe_split_flags( /* Avoid split loop looks for lowest voltage level that allows most unsplit pipes possible */ if (avoid_split) { + int max_mpc_comb = context->bw_ctx.dml.vba.maxMpcComb; + for (i = 0, pipe_idx = 0; i < dc->res_pool->pipe_count; i++) { if (!context->res_ctx.pipe_ctx[i].stream) continue; for (vlevel_split = vlevel; vlevel <= context->bw_ctx.dml.soc.num_states; vlevel++) - if (context->bw_ctx.dml.vba.NoOfDPP[vlevel][0][pipe_idx] == 1) + if (context->bw_ctx.dml.vba.NoOfDPP[vlevel][0][pipe_idx] == 1 && + context->bw_ctx.dml.vba.ModeSupport[vlevel][0]) break; /* Impossible to not split this pipe */ if (vlevel > context->bw_ctx.dml.soc.num_states) vlevel = vlevel_split; + else + max_mpc_comb = 0; pipe_idx++; } - context->bw_ctx.dml.vba.maxMpcComb = 0; + context->bw_ctx.dml.vba.maxMpcComb = max_mpc_comb; } /* Split loop sets which pipe should be split based on dml outputs and dc flags */ |