Skip to content

Commit 84c63d0

Browse files
Nikola Cornijalexdeucher
authored andcommitted
drm/amd/display: Use the correct max downscaling value for DCN3.x family
[why] As per spec, DCN3.x can do 6:1 downscaling and DCN2.x can do 4:1. The max downscaling limit value for DCN2.x is 250, which means it's calculated as 1000 / 4 = 250. For DCN3.x this then gives 1000 / 6 = 167. [how] Set maximum downscaling limit to 167 for DCN3.x Signed-off-by: Nikola Cornij <nikola.cornij@amd.com> Reviewed-by: Charlene Liu <Charlene.Liu@amd.com> Reviewed-by: Harry Wentland <Harry.Wentland@amd.com> Acked-by: Stylon Wang <stylon.wang@amd.com> Tested-by: Daniel Wheeler <daniel.wheeler@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org
1 parent d07f6ca commit 84c63d0

3 files changed

Lines changed: 12 additions & 9 deletions

File tree

drivers/gpu/drm/amd/display/dc/dcn30/dcn30_resource.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -826,10 +826,11 @@ static const struct dc_plane_cap plane_cap = {
826826
.fp16 = 16000
827827
},
828828

829+
/* 6:1 downscaling ratio: 1000/6 = 166.666 */
829830
.max_downscale_factor = {
830-
.argb8888 = 600,
831-
.nv12 = 600,
832-
.fp16 = 600
831+
.argb8888 = 167,
832+
.nv12 = 167,
833+
.fp16 = 167
833834
}
834835
};
835836

drivers/gpu/drm/amd/display/dc/dcn301/dcn301_resource.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -843,10 +843,11 @@ static const struct dc_plane_cap plane_cap = {
843843
.fp16 = 16000
844844
},
845845

846+
/* 6:1 downscaling ratio: 1000/6 = 166.666 */
846847
.max_downscale_factor = {
847-
.argb8888 = 600,
848-
.nv12 = 600,
849-
.fp16 = 600
848+
.argb8888 = 167,
849+
.nv12 = 167,
850+
.fp16 = 167
850851
},
851852
64,
852853
64

drivers/gpu/drm/amd/display/dc/dcn302/dcn302_resource.c

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -284,10 +284,11 @@ static const struct dc_plane_cap plane_cap = {
284284
.nv12 = 16000,
285285
.fp16 = 16000
286286
},
287+
/* 6:1 downscaling ratio: 1000/6 = 166.666 */
287288
.max_downscale_factor = {
288-
.argb8888 = 600,
289-
.nv12 = 600,
290-
.fp16 = 600
289+
.argb8888 = 167,
290+
.nv12 = 167,
291+
.fp16 = 167
291292
},
292293
16,
293294
16

0 commit comments

Comments
 (0)