mirror of
https://github.com/torvalds/linux.git
synced 2026-09-22 04:34:03 +02:00
drm/amd/display: Fix redundant GPUVMEnable checks in dcn6 flip schedule
Inside dcn6_calculate_flip_schedule(), GPUVMEnable is already checked in
the outer if block. But the same GPUVMEnable is checked again in two
inner if blocks inside it. Since GPUVMEnable is always true at that
point, the inner else branches that assign meta_row_height are never
reached.
Remove the redundant inner GPUVMEnable checks and directly assign
dpte_row_height, which is always the correct value here.
Fixes: 7f7d7ea1fa ("drm/amd/display: Add new sources for DCN6")
Reported-by: Dan Carpenter <error27@gmail.com>
Cc: Roman Li <roman.li@amd.com>
Cc: Alex Hung <alex.hung@amd.com>
Cc: Tom Chung <chiahsuan.chung@amd.com>
Cc: Aurabindo Pillai <aurabindo.pillai@amd.com>
Signed-off-by: Srinivasan Shanmugam <srinivasan.shanmugam@amd.com>
Reviewed-by: George Zhang <george.zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
fdc290ff4a
commit
84298acf1c
|
|
@ -569,20 +569,11 @@ void dcn6_calculate_flip_schedule(
|
|||
|
||||
if (GPUVMEnable) {
|
||||
if (l->dual_plane) {
|
||||
if (GPUVMEnable) {
|
||||
l->min_row_height = dpte_row_height;
|
||||
l->min_row_height_chroma = dpte_row_height_chroma;
|
||||
} else {
|
||||
l->min_row_height = meta_row_height;
|
||||
l->min_row_height_chroma = meta_row_height_chroma;
|
||||
}
|
||||
l->min_row_height = dpte_row_height;
|
||||
l->min_row_height_chroma = dpte_row_height_chroma;
|
||||
l->min_row_time = math_min2(l->min_row_height * LineTime / VRatio, l->min_row_height_chroma * LineTime / VRatioChroma);
|
||||
} else {
|
||||
if (GPUVMEnable)
|
||||
l->min_row_height = dpte_row_height;
|
||||
else
|
||||
l->min_row_height = meta_row_height;
|
||||
|
||||
l->min_row_height = dpte_row_height;
|
||||
l->min_row_time = l->min_row_height * LineTime / VRatio;
|
||||
}
|
||||
DML_LOG_VERBOSE("DML::%s: min_row_time = %f\n", __func__, l->min_row_time);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user