Commit 06199554 authored by Trigger Huang's avatar Trigger Huang Committed by Alex Deucher

drm/amd/powerplay:Tonga not to start SMC if SRIOV

This patch is used for virtualization support. In virtualization case,
Tonga SMC should not be started and SMU firmware should not be loaded
if in SRIOV environment. The same operation will be applied on FIJI in
other patch.
Signed-off-by: default avatarMonk Liu <Monk.Liu@amd.com>
Signed-off-by: default avatarTrigger Huang <trigger.huang@amd.com>
Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent aa4747c0
...@@ -140,7 +140,8 @@ static int tonga_start_smu(struct pp_smumgr *smumgr) ...@@ -140,7 +140,8 @@ static int tonga_start_smu(struct pp_smumgr *smumgr)
int result; int result;
/* Only start SMC if SMC RAM is not running */ /* Only start SMC if SMC RAM is not running */
if (!smu7_is_smc_ram_running(smumgr)) { if (!(smu7_is_smc_ram_running(smumgr) ||
cgs_is_virtualization_enabled(smumgr->device))) {
/*Check if SMU is running in protected mode*/ /*Check if SMU is running in protected mode*/
if (0 == SMUM_READ_VFPF_INDIRECT_FIELD(smumgr->device, CGS_IND_REG__SMC, if (0 == SMUM_READ_VFPF_INDIRECT_FIELD(smumgr->device, CGS_IND_REG__SMC,
SMU_FIRMWARE, SMU_MODE)) { SMU_FIRMWARE, SMU_MODE)) {
......
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