Fiji seems to have difficulty with switching PCIe generations
including on my Instinct MI8, where it is basically stuck at Gen 1
unless manually switched by using a different PowerPlay profile.
(using the pp_dpm_pcie sysfs does not work)
18edef19ea44 introduced support for Fiji's SMU, which included setting
the PCIeBootLinkLevel value to zero which is equal to PCI Express Gen
1.
By copying what Tonga and other generations of AMD GPUs do, which is
to use the maximum value from the speed table, fixes the issue.
(p.s. I believe Topaz's SMU also has the same issue, I can send in an
additional patch if needed)
Fixes: 18edef19ea44 ("drm/amd/powerplay: implement fw image related
smu interface for Fiji.")
Signed-off-by: John Smith <[email protected]>
---
drivers/gpu/drm/amd/pm/powerplay/smumgr/fiji_smumgr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/amd/pm/powerplay/smumgr/fiji_smumgr.c
b/drivers/gpu/drm/amd/pm/powerplay/smumgr/fiji_smumgr.c
index d2dbd90bb427..0a876c840c79 100644
--- a/drivers/gpu/drm/amd/pm/powerplay/smumgr/fiji_smumgr.c
+++ b/drivers/gpu/drm/amd/pm/powerplay/smumgr/fiji_smumgr.c
@@ -2024,7 +2024,7 @@ static int fiji_init_smc_table(struct pp_hwmgr *hwmgr)
table->VoltageResponseTime = 0;
table->PhaseResponseTime = 0;
table->MemoryThermThrottleEnable = 1;
- table->PCIeBootLinkLevel = 0; /* 0:Gen1 1:Gen2 2:Gen3*/
+ table->PCIeBootLinkLevel = (uint8_t) (data->dpm_table.pcie_speed_table.count);
table->PCIeGenInterval = 1;
table->VRConfig = 0;