drm/amdgpu: add check_fw_version support for cyan_skillfish
authorLang Yu <Lang.Yu@amd.com>
Wed, 21 Jul 2021 15:05:07 +0000 (11:05 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 23 Jul 2021 14:08:02 +0000 (10:08 -0400)
Add check_fw_version function support for cyan_skillfish.

Signed-off-by: Lang Yu <Lang.Yu@amd.com>
Reviewed-by: Huang Rui <ray.huang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/pm/inc/smu_v11_0.h
drivers/gpu/drm/amd/pm/swsmu/smu11/cyan_skillfish_ppt.c
drivers/gpu/drm/amd/pm/swsmu/smu11/smu_v11_0.c

index 385b2ea..d8048c3 100644 (file)
@@ -35,6 +35,7 @@
 #define SMU11_DRIVER_IF_VERSION_VANGOGH 0x03
 #define SMU11_DRIVER_IF_VERSION_Dimgrey_Cavefish 0xF
 #define SMU11_DRIVER_IF_VERSION_Beige_Goby 0xD
+#define SMU11_DRIVER_IF_VERSION_Cyan_Skillfish 0x8
 
 /* MP Apertures */
 #define MP0_Public                     0x03800000
index 4fbffc1..b05f954 100644 (file)
@@ -57,6 +57,7 @@ static struct cmn2asic_msg_mapping cyan_skillfish_message_map[SMU_MSG_MAX_COUNT]
 static const struct pptable_funcs cyan_skillfish_ppt_funcs = {
 
        .check_fw_status = smu_v11_0_check_fw_status,
+       .check_fw_version = smu_v11_0_check_fw_version,
        .init_power = smu_v11_0_init_power,
        .fini_power = smu_v11_0_fini_power,
        .register_irq_handler = smu_v11_0_register_irq_handler,
index 0a5d46a..1ba57e5 100644 (file)
@@ -266,6 +266,9 @@ int smu_v11_0_check_fw_version(struct smu_context *smu)
        case CHIP_BEIGE_GOBY:
                smu->smc_driver_if_version = SMU11_DRIVER_IF_VERSION_Beige_Goby;
                break;
+       case CHIP_CYAN_SKILLFISH:
+               smu->smc_driver_if_version = SMU11_DRIVER_IF_VERSION_Cyan_Skillfish;
+               break;
        default:
                dev_err(smu->adev->dev, "smu unsupported asic type:%d.\n", smu->adev->asic_type);
                smu->smc_driver_if_version = SMU11_DRIVER_IF_VERSION_INV;