Commit 3a2c0ecc authored by Wenjing Liu's avatar Wenjing Liu Committed by Alex Deucher
Browse files

drm/amd/display: move odm power optimization decision after subvp optimization



[why]
ODM power optimization excludes subvp power optimization but subvp
optimization can override ODM power optimization even if subvp optimization
configuration is not found. This happens with 4k144hz + 1 5k desktop plane.
We could have applied ODM power optimization however this is overridden by
subvp but subvp ends up deciding not apply its optimization.

[how]
Move ODM power optimization decision after subvp so it will try ODM power
optimization after subvp optimization is not possible.

Reviewed-by: default avatarDillon Varone <dillon.varone@amd.com>
Acked-by: default avatarStylon Wang <stylon.wang@amd.com>
Signed-off-by: default avatarWenjing Liu <wenjing.liu@amd.com>
Tested-by: default avatarDaniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 15c6798a
Loading
Loading
Loading
Loading
+5 −4
Original line number Diff line number Diff line
@@ -1441,10 +1441,6 @@ static void dcn32_full_validate_bw_helper(struct dc *dc,
		vba->VoltageLevel = *vlevel;
	}

	if (should_allow_odm_power_optimization(dc, context, vba, split, merge))
		try_odm_power_optimization_and_revalidate(
				dc, context, pipes, split, merge, vlevel, *pipe_cnt);

	/* Conditions for setting up phantom pipes for SubVP:
	 * 1. Not force disable SubVP
	 * 2. Full update (i.e. !fast_validate)
@@ -1563,6 +1559,11 @@ static void dcn32_full_validate_bw_helper(struct dc *dc,
			assign_subvp_index(dc, context);
		}
	}

	if (should_allow_odm_power_optimization(dc, context, vba, split, merge))
		try_odm_power_optimization_and_revalidate(
				dc, context, pipes, split, merge, vlevel, *pipe_cnt);

}

static bool is_dtbclk_required(struct dc *dc, struct dc_state *context)