drm/amdgpu/gmc8: update MC firmware for polaris
Subsystems (2)
PATCH 1/2 drm/amdgpu/gmc8: update MC firmware for polaris
Some variants require different MC firmware images.
--- drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-)
drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c +24 -5
@@ -56,6 +56,8 @@ MODULE_FIRMWARE("amdgpu/tonga_mc.bin");MODULE_FIRMWARE ("amdgpu/polaris11_mc.bin" );MODULE_FIRMWARE ("amdgpu/polaris10_mc.bin" );MODULE_FIRMWARE ("amdgpu/polaris12_mc.bin" ); +MODULE_FIRMWARE ("amdgpu/polaris11_k_mc.bin" ); +MODULE_FIRMWARE ("amdgpu/polaris10_k_mc.bin" );MODULE_FIRMWARE ("amdgpu/polaris12_k_mc.bin" ); static const u32 golden_settings_tonga_a11[] =
@@ -225,22 +227,39 @@ static int gmc_v8_0_init_microcode(struct amdgpu_device *adev) chip_name ="tonga" ;break ;case CHIP_POLARIS11 : - chip_name ="polaris11" ; +if (((adev->pdev->device ==0x67ef ) && + ((adev->pdev->revision ==0xe0 ) || + (adev->pdev->revision ==0xe5 ))) || + ((adev->pdev->device ==0x67ff ) && + ((adev->pdev->revision ==0xcf ) || + (adev->pdev->revision ==0xef ) || + (adev->pdev->revision ==0xff )))) + chip_name ="polaris11_k" ; +else if ((adev->pdev->device ==0x67ef ) && + (adev->pdev->revision ==0xe2 )) + chip_name ="polaris11_k" ; +else + chip_name ="polaris11" ;break ;case CHIP_POLARIS10 : - chip_name ="polaris10" ; +if ((adev->pdev->device ==0x67df ) && + ((adev->pdev->revision ==0xe1 ) || + (adev->pdev->revision ==0xf7 ))) + chip_name ="polaris10_k" ; +else + chip_name ="polaris10" ;break ;case CHIP_POLARIS12 : - chip_name ="polaris12" ;if (((adev->pdev->device ==0x6987 ) && ((adev->pdev->revision ==0xc0 ) || (adev->pdev->revision ==0xc3 ))) || ((adev->pdev->device ==0x6981 ) && ((adev->pdev->revision ==0x00 ) || (adev->pdev->revision ==0x01 ) || - (adev->pdev->revision ==0x10 )))) { + (adev->pdev->revision ==0x10 )))) chip_name ="polaris12_k" ; - } +else + chip_name ="polaris12" ;break ;case CHIP_FIJI :case CHIP_CARRIZO :
Signature · 6 lines
2.13.6 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
A message that is not in the archive (sent off-list or not yet received): 20181203144736.8387-1-alexander.deucher-5C7GfCeVMHo@public.gmane.org
PATCH 2/2 drm/amdgpu/gmc8: always load MC firmware in the driver
Some power features rely on the driver loaded version so always load the MC firmware from the driver even if the vbios loaded a version already.
--- drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-)
drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c +1 -8
@@ -366,7 +366,7 @@ static int gmc_v8_0_polaris_mc_load_microcode(struct amdgpu_device *adev)const struct mc_firmware_header_v1_0 *hdr;const __le32 *fw_data =NULL ;const __le32 *io_mc_regs =NULL ; -u32 data, vbios_version; +u32 data;int i, ucode_size, regs_size;/* Skip MC ucode loading on SR-IOV capable boards.
@@ -377,13 +377,6 @@ static int gmc_v8_0_polaris_mc_load_microcode(struct amdgpu_device *adev)if (amdgpu_sriov_bios (adev))return 0 ; -WREG32 (mmMC_SEQ_IO_DEBUG_INDEX,0x9F ); - data =RREG32 (mmMC_SEQ_IO_DEBUG_DATA); - vbios_version = data &0xf ; - -if (vbios_version ==0 ) -return 0 ; -if (!adev->gmc.fw)return -EINVAL ;
Signature · 6 lines
2.13.6 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Christian König
Acked-byAm 03.12.18 um 15:47 schrieb Alex Deucher:
Quoted 4 lines
Some variants require different MC firmware images.
Reviewed-by Junwei Zhang <[email protected]>Signed-off-by Alex Deucher <[email protected]>
Quoted 52 lines
--- drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-)drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c +21
-3@@ -56,6 +56,8 @@ MODULE_FIRMWARE("amdgpu/tonga_mc.bin");MODULE_FIRMWARE ("amdgpu/polaris11_mc.bin" );MODULE_FIRMWARE ("amdgpu/polaris10_mc.bin" );MODULE_FIRMWARE ("amdgpu/polaris12_mc.bin" ); +MODULE_FIRMWARE ("amdgpu/polaris11_k_mc.bin" ); +MODULE_FIRMWARE ("amdgpu/polaris10_k_mc.bin" );MODULE_FIRMWARE ("amdgpu/polaris12_k_mc.bin" ); static const u32 golden_settings_tonga_a11[] =@@ -225,22 +227,39 @@ static int gmc_v8_0_init_microcode(struct amdgpu_device *adev) chip_name ="tonga" ;break ;case CHIP_POLARIS11 : - chip_name ="polaris11" ; +if (((adev->pdev->device ==0x67ef ) && + ((adev->pdev->revision ==0xe0 ) || + (adev->pdev->revision ==0xe5 ))) || + ((adev->pdev->device ==0x67ff ) && + ((adev->pdev->revision ==0xcf ) || + (adev->pdev->revision ==0xef ) || + (adev->pdev->revision ==0xff )))) + chip_name ="polaris11_k" ; +else if ((adev->pdev->device ==0x67ef ) && + (adev->pdev->revision ==0xe2 )) + chip_name ="polaris11_k" ; +else + chip_name ="polaris11" ;break ;case CHIP_POLARIS10 : - chip_name ="polaris10" ; +if ((adev->pdev->device ==0x67df ) && + ((adev->pdev->revision ==0xe1 ) || + (adev->pdev->revision ==0xf7 ))) + chip_name ="polaris10_k" ; +else + chip_name ="polaris10" ;break ;case CHIP_POLARIS12 : - chip_name ="polaris12" ; if (((adev->pdev->device == 0x6987) && ((adev->pdev->revision == 0xc0) || (adev->pdev->revision == 0xc3))) || ((adev->pdev->device == 0x6981) && ((adev->pdev->revision == 0x00) ||
drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c static int gmc_v8_0_init_microcode(struct amdgpu_device *adev) · line 265
Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/gmc_v8_0.c +3
-2(adev->pdev->revision == 0x01) || - (adev->pdev->revision == 0x10)))) { + (adev->pdev->revision == 0x10)))) chip_name ="polaris12_k" ; - } + else + chip_name ="polaris12" ;break ;case CHIP_FIJI :case CHIP_CARRIZO :
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx