drm/amd/powerplay: drop unnecessary wrapper .populate_smc_tables
authorEvan Quan <evan.quan@amd.com>
Mon, 8 Jun 2020 11:49:08 +0000 (19:49 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 1 Jul 2020 05:59:19 +0000 (01:59 -0400)
Since .populate_smc_tables is just a wrapper of .set_default_dpm_table.

Signed-off-by: Evan Quan <evan.quan@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h
drivers/gpu/drm/amd/powerplay/navi10_ppt.c
drivers/gpu/drm/amd/powerplay/renoir_ppt.c
drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
drivers/gpu/drm/amd/powerplay/smu_internal.h
drivers/gpu/drm/amd/powerplay/smu_v11_0.c
drivers/gpu/drm/amd/powerplay/smu_v12_0.c

index 89dd12536d586d61ba98be277db9afd6b6a591af..78263de0267800deb88f71439a7a467268c51052 100644 (file)
@@ -813,7 +813,7 @@ static int smu_late_init(void *handle)
         * gfxclk, memclk, dcefclk, and etc. And enable the DPM feature for each
         * type of clks.
         */
-       ret = smu_populate_smc_tables(smu);
+       ret = smu_set_default_dpm_table(smu);
        if (ret) {
                dev_err(adev->dev, "Failed to setup default dpm clock tables!\n");
                return ret;
index 2a9818a6bf80ddd19e1296a3348204e87d55ba9d..54e8c15408ec51a076606387157ce87bf2bb6762 100644 (file)
@@ -2587,7 +2587,6 @@ static const struct pptable_funcs arcturus_ppt_funcs = {
        /* pptable related */
        .setup_pptable = arcturus_setup_pptable,
        .get_vbios_bootup_values = smu_v11_0_get_vbios_bootup_values,
-       .populate_smc_tables = smu_v11_0_populate_smc_pptable,
        .check_fw_version = smu_v11_0_check_fw_version,
        .write_pptable = smu_v11_0_write_pptable,
        .set_driver_table_location = smu_v11_0_set_driver_table_location,
index 5f90ecd810c8f0ac58a76e9a5a49405c6dd844f0..a28d6b03b65bd41eb0c870d1a6553f8e8cb5d378 100644 (file)
@@ -505,7 +505,6 @@ struct pptable_funcs {
        int (*check_fw_status)(struct smu_context *smu);
        int (*setup_pptable)(struct smu_context *smu);
        int (*get_vbios_bootup_values)(struct smu_context *smu);
-       int (*populate_smc_tables)(struct smu_context *smu);
        int (*check_fw_version)(struct smu_context *smu);
        int (*powergate_sdma)(struct smu_context *smu, bool gate);
        int (*set_gfx_cgpg)(struct smu_context *smu, bool enable);
index debb30aa78c517b02af71dfba3622b06d15b0747..4fb911d8b49c463ff99a2a1601c15bc71191aea0 100644 (file)
@@ -164,8 +164,6 @@ int smu_v11_0_setup_pptable(struct smu_context *smu);
 
 int smu_v11_0_get_vbios_bootup_values(struct smu_context *smu);
 
-int smu_v11_0_populate_smc_pptable(struct smu_context *smu);
-
 int smu_v11_0_check_fw_version(struct smu_context *smu);
 
 int smu_v11_0_write_pptable(struct smu_context *smu);
index 7fbebc1979cf15ed884e5b920109e66756e3c253..d29f7522398749d163f526390eb7d13d39ebda63 100644 (file)
@@ -72,7 +72,7 @@ int smu_v12_0_init_smc_tables(struct smu_context *smu);
 
 int smu_v12_0_fini_smc_tables(struct smu_context *smu);
 
-int smu_v12_0_populate_smc_tables(struct smu_context *smu);
+int smu_v12_0_set_default_dpm_tables(struct smu_context *smu);
 
 int smu_v12_0_get_enabled_mask(struct smu_context *smu,
                                      uint32_t *feature_mask, uint32_t num);
index 616bf466f203642de9aeafd3e04f635121d61cde..6c2f582bad5d2a2488a215072006752fd8280edd 100644 (file)
@@ -2423,7 +2423,6 @@ static const struct pptable_funcs navi10_ppt_funcs = {
        .check_fw_status = smu_v11_0_check_fw_status,
        .setup_pptable = navi10_setup_pptable,
        .get_vbios_bootup_values = smu_v11_0_get_vbios_bootup_values,
-       .populate_smc_tables = smu_v11_0_populate_smc_pptable,
        .check_fw_version = smu_v11_0_check_fw_version,
        .write_pptable = smu_v11_0_write_pptable,
        .set_driver_table_location = smu_v11_0_set_driver_table_location,
index 6b5e60b4c039a3e2ba48465c2a82dc7ace17b50c..f286c1e1934fc55af8166470bc94704cbb230e91 100644 (file)
@@ -951,7 +951,7 @@ static const struct pptable_funcs renoir_ppt_funcs = {
        .gfx_off_control = smu_v12_0_gfx_off_control,
        .init_smc_tables = smu_v12_0_init_smc_tables,
        .fini_smc_tables = smu_v12_0_fini_smc_tables,
-       .populate_smc_tables = smu_v12_0_populate_smc_tables,
+       .set_default_dpm_table = smu_v12_0_set_default_dpm_tables,
        .get_enabled_mask = smu_v12_0_get_enabled_mask,
        .get_current_clk_freq = smu_v12_0_get_current_clk_freq,
        .get_dpm_ultimate_freq = smu_v12_0_get_dpm_ultimate_freq,
index 127df2953979ada428a192923ba547cb96a0b5a5..769e031d489ad670cab8251d6019bf30705937d2 100644 (file)
@@ -2593,7 +2593,6 @@ static const struct pptable_funcs sienna_cichlid_ppt_funcs = {
        .check_fw_status = smu_v11_0_check_fw_status,
        .setup_pptable = sienna_cichlid_setup_pptable,
        .get_vbios_bootup_values = smu_v11_0_get_vbios_bootup_values,
-       .populate_smc_tables = smu_v11_0_populate_smc_pptable,
        .check_fw_version = smu_v11_0_check_fw_version,
        .write_pptable = smu_v11_0_write_pptable,
        .set_driver_table_location = smu_v11_0_set_driver_table_location,
index 935460f2ceadf35686b537ee0d38feb8b51cf627..149f5e50e6195a71032c40cd8949c4ee897f5a48 100644 (file)
@@ -45,8 +45,6 @@
 
 #define smu_get_vbios_bootup_values(smu) \
        ((smu)->ppt_funcs->get_vbios_bootup_values ? (smu)->ppt_funcs->get_vbios_bootup_values((smu)) : 0)
-#define smu_populate_smc_tables(smu) \
-       ((smu)->ppt_funcs->populate_smc_tables ? (smu)->ppt_funcs->populate_smc_tables((smu)) : 0)
 #define smu_check_fw_version(smu) \
        ((smu)->ppt_funcs->check_fw_version ? (smu)->ppt_funcs->check_fw_version((smu)) : 0)
 #define smu_write_pptable(smu) \
index 0a8645854b469df349308f61cfecabddf8457531..9d29aa4e3a5d3a5dd624aebda4d1d1536d4e88d6 100644 (file)
@@ -750,15 +750,6 @@ int smu_v11_0_notify_memory_pool_location(struct smu_context *smu)
        return ret;
 }
 
-int smu_v11_0_populate_smc_pptable(struct smu_context *smu)
-{
-       int ret;
-
-       ret = smu_set_default_dpm_table(smu);
-
-       return ret;
-}
-
 int smu_v11_0_write_pptable(struct smu_context *smu)
 {
        struct smu_table_context *table_context = &smu->smu_table;
index f10113fc4571d28b4a849d014dd5a608db4aa85a..5b56e7579ff4c8d3446c05dab26b6a7e2fe13166 100644 (file)
@@ -319,7 +319,7 @@ int smu_v12_0_fini_smc_tables(struct smu_context *smu)
        return 0;
 }
 
-int smu_v12_0_populate_smc_tables(struct smu_context *smu)
+int smu_v12_0_set_default_dpm_tables(struct smu_context *smu)
 {
        struct smu_table_context *smu_table = &smu->smu_table;