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

Commit 904aa42e authored by Eric Yang's avatar Eric Yang Committed by Alex Deucher
Browse files

drm/amd/display: add back removed hack for mpcc add



A previous changed removed the hack to match mpcc_idd
with mi instance. This causes pstate hang on resume
from hibernate for yet unknown reason. Add the hack
back for now to work around the issue. More debugging
required in init_hw to root cause the hang.

Signed-off-by: default avatarEric Yang <Eric.Yang2@amd.com>
Reviewed-by: default avatarTony Cheng <Tony.Cheng@amd.com>
Acked-by: default avatarHarry Wentland <Harry.Wentland@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 25bab0da
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -279,6 +279,18 @@ static int mpc10_mpcc_add(struct mpc *mpc, struct mpcc_cfg *cfg)
	if (z_idx == cfg->tree_cfg->num_pipes) {
		ASSERT(cfg->z_index <= cfg->tree_cfg->num_pipes);
		mpcc_id = mpc10_get_idle_mpcc_id(mpc10);

		/*
		 * TODO: remove hack
		 * Note: currently there is a bug in init_hw such that
		 * on resume from hibernate, BIOS sets up MPCC0, and
		 * we do mpcc_remove but the mpcc cannot go to idle
		 * after remove. This cause us to pick mpcc1 here,
		 * which causes a pstate hang for yet unknown reason.
		 */
		mpcc_id = cfg->dpp_id;
		/* end hack*/

		ASSERT(!(mpc10->mpcc_in_use_mask & 1 << mpcc_id));

		if (mpc->ctx->dc->debug.sanity_checks)