drm/amd/powerplay: fix request smc_sk firmware case
This patch fixes firmware request error on polaris protection mode. Because we need load smc_sk instead of smc under security protection mode. Signed-off-by: Huang Rui <ray.huang@amd.com> Tested-by: Evan Quan <evan.quan@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
@@ -713,6 +713,7 @@ static int amdgpu_cgs_rel_firmware(struct cgs_device *cgs_device, enum cgs_ucode
|
|||||||
CGS_FUNC_ADEV;
|
CGS_FUNC_ADEV;
|
||||||
if ((CGS_UCODE_ID_SMU == type) || (CGS_UCODE_ID_SMU_SK == type)) {
|
if ((CGS_UCODE_ID_SMU == type) || (CGS_UCODE_ID_SMU_SK == type)) {
|
||||||
release_firmware(adev->pm.fw);
|
release_firmware(adev->pm.fw);
|
||||||
|
adev->pm.fw = NULL;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
/* cannot release other firmware because they are not created by cgs */
|
/* cannot release other firmware because they are not created by cgs */
|
||||||
@@ -808,6 +809,9 @@ static int amdgpu_cgs_get_firmware_info(struct cgs_device *cgs_device,
|
|||||||
const uint8_t *src;
|
const uint8_t *src;
|
||||||
const struct smc_firmware_header_v1_0 *hdr;
|
const struct smc_firmware_header_v1_0 *hdr;
|
||||||
|
|
||||||
|
if (CGS_UCODE_ID_SMU_SK == type)
|
||||||
|
amdgpu_cgs_rel_firmware(cgs_device, CGS_UCODE_ID_SMU);
|
||||||
|
|
||||||
if (!adev->pm.fw) {
|
if (!adev->pm.fw) {
|
||||||
switch (adev->asic_type) {
|
switch (adev->asic_type) {
|
||||||
case CHIP_TOPAZ:
|
case CHIP_TOPAZ:
|
||||||
|
Reference in New Issue
Block a user