Commit edddc6fd authored by Evan Quan's avatar Evan Quan Committed by Alex Deucher

drm/amd/pm: correct the baco state setting for ArmD3 scenario

The check for baco support relies on the correct baco state.
Signed-off-by: default avatarEvan Quan <evan.quan@amd.com>
Reviewed-by: default avatarFeifei Xu <feifei.xu@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent b299221f
......@@ -2229,10 +2229,23 @@ int smu_v13_0_gfx_ulv_control(struct smu_context *smu,
int smu_v13_0_baco_set_armd3_sequence(struct smu_context *smu,
enum smu_baco_seq baco_seq)
{
return smu_cmn_send_smc_msg_with_param(smu,
SMU_MSG_ArmD3,
baco_seq,
NULL);
struct smu_baco_context *smu_baco = &smu->smu_baco;
int ret;
ret = smu_cmn_send_smc_msg_with_param(smu,
SMU_MSG_ArmD3,
baco_seq,
NULL);
if (ret)
return ret;
if (baco_seq == BACO_SEQ_BAMACO ||
baco_seq == BACO_SEQ_BACO)
smu_baco->state = SMU_BACO_STATE_ENTER;
else
smu_baco->state = SMU_BACO_STATE_EXIT;
return 0;
}
bool smu_v13_0_baco_is_support(struct smu_context *smu)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment