Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 12fa0fdb authored by Bindu Ramamurthy's avatar Bindu Ramamurthy Committed by Greg Kroah-Hartman
Browse files

drm/amd/display: Allow bandwidth validation for 0 streams.



[ Upstream commit ba8e59773ae59818695d1e20b8939282da80ec8c ]

[Why]
Bandwidth calculations are triggered for non zero streams, and
in case of 0 streams, these calculations were skipped with
pstate status not being updated.

[How]
As the pstate status is applicable for non zero streams, check
added for allowing 0 streams inline with dcn internal bandwidth
validations.

Signed-off-by: default avatarBindu Ramamurthy <bindu.r@amd.com>
Reviewed-by: default avatarRoman Li <Roman.Li@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 8c48345f
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -2917,7 +2917,7 @@ bool dcn20_validate_bandwidth(struct dc *dc, struct dc_state *context,
	voltage_supported = dcn20_validate_bandwidth_internal(dc, context, false);
	dummy_pstate_supported = context->bw_ctx.bw.dcn.clk.p_state_change_support;

	if (voltage_supported && dummy_pstate_supported) {
	if (voltage_supported && (dummy_pstate_supported || !(context->stream_count))) {
		context->bw_ctx.bw.dcn.clk.p_state_change_support = false;
		goto restore_dml_state;
	}