All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/2] drm/amd/powerplay: drop redundant .set_min_dcefclk_deep_sleep API
@ 2020-06-09 10:09 Evan Quan
  2020-06-09 10:09 ` [PATCH 2/2] drm/amd/powerplay: drop unnecessary wrapper .populate_smc_tables Evan Quan
  2020-06-09 19:49 ` [PATCH 1/2] drm/amd/powerplay: drop redundant .set_min_dcefclk_deep_sleep API Alex Deucher
  0 siblings, 2 replies; 4+ messages in thread
From: Evan Quan @ 2020-06-09 10:09 UTC (permalink / raw)
  To: amd-gfx; +Cc: alexander.deucher, Evan Quan

It has exactly the same functionality as .set_deep_sleep_dcefclk.

Change-Id: Ib4d2d604ca014e194cb2b61ac770e4370ecad74d
Signed-off-by: Evan Quan <evan.quan@amd.com>
---
 drivers/gpu/drm/amd/powerplay/amdgpu_smu.c         | 11 +++++------
 drivers/gpu/drm/amd/powerplay/arcturus_ppt.c       |  3 +--
 drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h     |  1 -
 drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h      |  2 --
 drivers/gpu/drm/amd/powerplay/navi10_ppt.c         |  1 -
 drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c |  3 +--
 drivers/gpu/drm/amd/powerplay/smu_internal.h       |  4 ++--
 drivers/gpu/drm/amd/powerplay/smu_v11_0.c          | 10 ----------
 8 files changed, 9 insertions(+), 26 deletions(-)

diff --git a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
index 6beae3b496be..89dd12536d58 100644
--- a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
+++ b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
@@ -1269,7 +1269,8 @@ static int smu_smc_hw_setup(struct smu_context *smu)
 	 * Set min deep sleep dce fclk with bootup value from vbios via
 	 * SetMinDeepSleepDcefclk MSG.
 	 */
-	ret = smu_set_min_dcef_deep_sleep(smu);
+	ret = smu_set_min_dcef_deep_sleep(smu,
+					  smu->smu_table.boot_values.dcefclk / 100);
 	if (ret)
 		return ret;
 
@@ -1584,9 +1585,8 @@ int smu_display_configuration_change(struct smu_context *smu,
 
 	mutex_lock(&smu->mutex);
 
-	if (smu->ppt_funcs->set_deep_sleep_dcefclk)
-		smu->ppt_funcs->set_deep_sleep_dcefclk(smu,
-				display_config->min_dcef_deep_sleep_set_clk / 100);
+	smu_set_min_dcef_deep_sleep(smu,
+				    display_config->min_dcef_deep_sleep_set_clk / 100);
 
 	for (index = 0; index < display_config->num_path_including_non_display; index++) {
 		if (display_config->displays[index].controller_id != 0)
@@ -2482,8 +2482,7 @@ int smu_set_deep_sleep_dcefclk(struct smu_context *smu, int clk)
 
 	mutex_lock(&smu->mutex);
 
-	if (smu->ppt_funcs->set_deep_sleep_dcefclk)
-		ret = smu->ppt_funcs->set_deep_sleep_dcefclk(smu, clk);
+	ret = smu_set_min_dcef_deep_sleep(smu, clk);
 
 	mutex_unlock(&smu->mutex);
 
diff --git a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
index c104844b28f1..96c9a348f8b3 100644
--- a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
+++ b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
@@ -2590,7 +2590,6 @@ static const struct pptable_funcs arcturus_ppt_funcs = {
 	.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_min_dcef_deep_sleep = NULL,
 	.set_driver_table_location = smu_v11_0_set_driver_table_location,
 	.set_tool_table_location = smu_v11_0_set_tool_table_location,
 	.notify_memory_pool_location = smu_v11_0_notify_memory_pool_location,
@@ -2605,7 +2604,7 @@ static const struct pptable_funcs arcturus_ppt_funcs = {
 	.init_max_sustainable_clocks = smu_v11_0_init_max_sustainable_clocks,
 	.enable_thermal_alert = smu_v11_0_enable_thermal_alert,
 	.disable_thermal_alert = smu_v11_0_disable_thermal_alert,
-	.set_deep_sleep_dcefclk = smu_v11_0_set_deep_sleep_dcefclk,
+	.set_deep_sleep_dcefclk = NULL,
 	.display_clock_voltage_request = smu_v11_0_display_clock_voltage_request,
 	.get_fan_control_mode = smu_v11_0_get_fan_control_mode,
 	.set_fan_control_mode = smu_v11_0_set_fan_control_mode,
diff --git a/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h b/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
index 8eaa6338ad44..3420a58fad03 100644
--- a/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
+++ b/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
@@ -510,7 +510,6 @@ struct pptable_funcs {
 	int (*powergate_sdma)(struct smu_context *smu, bool gate);
 	int (*set_gfx_cgpg)(struct smu_context *smu, bool enable);
 	int (*write_pptable)(struct smu_context *smu);
-	int (*set_min_dcef_deep_sleep)(struct smu_context *smu);
 	int (*set_driver_table_location)(struct smu_context *smu);
 	int (*set_tool_table_location)(struct smu_context *smu);
 	int (*notify_memory_pool_location)(struct smu_context *smu);
diff --git a/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h b/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
index 2e9939beb128..9ccf62e99dcb 100644
--- a/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
+++ b/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
@@ -170,8 +170,6 @@ int smu_v11_0_check_fw_version(struct smu_context *smu);
 
 int smu_v11_0_write_pptable(struct smu_context *smu);
 
-int smu_v11_0_set_min_dcef_deep_sleep(struct smu_context *smu);
-
 int smu_v11_0_set_driver_table_location(struct smu_context *smu);
 
 int smu_v11_0_set_tool_table_location(struct smu_context *smu);
diff --git a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c b/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
index 115794557190..abbfcce6d9ad 100644
--- a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
+++ b/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
@@ -2426,7 +2426,6 @@ static const struct pptable_funcs navi10_ppt_funcs = {
 	.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_min_dcef_deep_sleep = smu_v11_0_set_min_dcef_deep_sleep,
 	.set_driver_table_location = smu_v11_0_set_driver_table_location,
 	.set_tool_table_location = smu_v11_0_set_tool_table_location,
 	.notify_memory_pool_location = smu_v11_0_notify_memory_pool_location,
diff --git a/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c b/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
index 81cc04de9b06..6a9d04cac240 100644
--- a/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
+++ b/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
@@ -2596,7 +2596,6 @@ static const struct pptable_funcs sienna_cichlid_ppt_funcs = {
 	.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_min_dcef_deep_sleep = NULL,
 	.set_driver_table_location = smu_v11_0_set_driver_table_location,
 	.set_tool_table_location = smu_v11_0_set_tool_table_location,
 	.notify_memory_pool_location = smu_v11_0_notify_memory_pool_location,
@@ -2611,7 +2610,7 @@ static const struct pptable_funcs sienna_cichlid_ppt_funcs = {
 	.init_max_sustainable_clocks = smu_v11_0_init_max_sustainable_clocks,
 	.enable_thermal_alert = smu_v11_0_enable_thermal_alert,
 	.disable_thermal_alert = smu_v11_0_disable_thermal_alert,
-	.set_deep_sleep_dcefclk = smu_v11_0_set_deep_sleep_dcefclk,
+	.set_deep_sleep_dcefclk = NULL,
 	.display_clock_voltage_request = smu_v11_0_display_clock_voltage_request,
 	.get_fan_control_mode = smu_v11_0_get_fan_control_mode,
 	.set_fan_control_mode = smu_v11_0_set_fan_control_mode,
diff --git a/drivers/gpu/drm/amd/powerplay/smu_internal.h b/drivers/gpu/drm/amd/powerplay/smu_internal.h
index 094db34ddbd1..86c09098963a 100644
--- a/drivers/gpu/drm/amd/powerplay/smu_internal.h
+++ b/drivers/gpu/drm/amd/powerplay/smu_internal.h
@@ -51,8 +51,8 @@
 	((smu)->ppt_funcs->check_fw_version ? (smu)->ppt_funcs->check_fw_version((smu)) : 0)
 #define smu_write_pptable(smu) \
 	((smu)->ppt_funcs->write_pptable ? (smu)->ppt_funcs->write_pptable((smu)) : 0)
-#define smu_set_min_dcef_deep_sleep(smu) \
-	((smu)->ppt_funcs->set_min_dcef_deep_sleep ? (smu)->ppt_funcs->set_min_dcef_deep_sleep((smu)) : 0)
+#define smu_set_min_dcef_deep_sleep(smu, clk) \
+	((smu)->ppt_funcs->set_deep_sleep_dcefclk ? (smu)->ppt_funcs->set_deep_sleep_dcefclk((smu), (clk)) : 0)
 #define smu_set_driver_table_location(smu) \
 	((smu)->ppt_funcs->set_driver_table_location ? (smu)->ppt_funcs->set_driver_table_location((smu)) : 0)
 #define smu_set_tool_table_location(smu) \
diff --git a/drivers/gpu/drm/amd/powerplay/smu_v11_0.c b/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
index 06e3799aa923..5590dab46e8c 100644
--- a/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
+++ b/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
@@ -782,16 +782,6 @@ int smu_v11_0_set_deep_sleep_dcefclk(struct smu_context *smu, uint32_t clk)
 	return ret;
 }
 
-int smu_v11_0_set_min_dcef_deep_sleep(struct smu_context *smu)
-{
-	struct smu_table_context *table_context = &smu->smu_table;
-
-	if (!table_context)
-		return -EINVAL;
-
-	return smu_v11_0_set_deep_sleep_dcefclk(smu, table_context->boot_values.dcefclk / 100);
-}
-
 int smu_v11_0_set_driver_table_location(struct smu_context *smu)
 {
 	struct smu_table *driver_table = &smu->smu_table.driver_table;
-- 
2.27.0

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH 2/2] drm/amd/powerplay: drop unnecessary wrapper .populate_smc_tables
  2020-06-09 10:09 [PATCH 1/2] drm/amd/powerplay: drop redundant .set_min_dcefclk_deep_sleep API Evan Quan
@ 2020-06-09 10:09 ` Evan Quan
  2020-06-09 19:51   ` Alex Deucher
  2020-06-09 19:49 ` [PATCH 1/2] drm/amd/powerplay: drop redundant .set_min_dcefclk_deep_sleep API Alex Deucher
  1 sibling, 1 reply; 4+ messages in thread
From: Evan Quan @ 2020-06-09 10:09 UTC (permalink / raw)
  To: amd-gfx; +Cc: alexander.deucher, Evan Quan

Since .populate_smc_tables is just a wrapper of .set_default_dpm_table.

Change-Id: I80e89146359d6cf5d80f1887878d371b41b41cb0
Signed-off-by: Evan Quan <evan.quan@amd.com>
---
 drivers/gpu/drm/amd/powerplay/amdgpu_smu.c         | 2 +-
 drivers/gpu/drm/amd/powerplay/arcturus_ppt.c       | 1 -
 drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h     | 1 -
 drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h      | 2 --
 drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h      | 2 +-
 drivers/gpu/drm/amd/powerplay/navi10_ppt.c         | 1 -
 drivers/gpu/drm/amd/powerplay/renoir_ppt.c         | 2 +-
 drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c | 1 -
 drivers/gpu/drm/amd/powerplay/smu_internal.h       | 2 --
 drivers/gpu/drm/amd/powerplay/smu_v11_0.c          | 9 ---------
 drivers/gpu/drm/amd/powerplay/smu_v12_0.c          | 2 +-
 11 files changed, 4 insertions(+), 21 deletions(-)

diff --git a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
index 89dd12536d58..78263de02678 100644
--- a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
+++ b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
@@ -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;
diff --git a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
index 96c9a348f8b3..ee492fc77414 100644
--- a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
+++ b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
@@ -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,
diff --git a/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h b/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
index 3420a58fad03..0d1429fc791b 100644
--- a/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
+++ b/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
@@ -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);
diff --git a/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h b/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
index 9ccf62e99dcb..d6cd3d74dcfa 100644
--- a/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
+++ b/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
@@ -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);
diff --git a/drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h b/drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h
index 7fbebc1979cf..d29f75223987 100644
--- a/drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h
+++ b/drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h
@@ -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);
diff --git a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c b/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
index abbfcce6d9ad..ef04ab1eba94 100644
--- a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
+++ b/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
@@ -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,
diff --git a/drivers/gpu/drm/amd/powerplay/renoir_ppt.c b/drivers/gpu/drm/amd/powerplay/renoir_ppt.c
index 6b5e60b4c039..f286c1e1934f 100644
--- a/drivers/gpu/drm/amd/powerplay/renoir_ppt.c
+++ b/drivers/gpu/drm/amd/powerplay/renoir_ppt.c
@@ -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,
diff --git a/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c b/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
index 6a9d04cac240..9a05fda05355 100644
--- a/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
+++ b/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
@@ -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,
diff --git a/drivers/gpu/drm/amd/powerplay/smu_internal.h b/drivers/gpu/drm/amd/powerplay/smu_internal.h
index 86c09098963a..03679eb21e0d 100644
--- a/drivers/gpu/drm/amd/powerplay/smu_internal.h
+++ b/drivers/gpu/drm/amd/powerplay/smu_internal.h
@@ -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) \
diff --git a/drivers/gpu/drm/amd/powerplay/smu_v11_0.c b/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
index 5590dab46e8c..9e3fee9e4aca 100644
--- a/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
+++ b/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
@@ -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;
diff --git a/drivers/gpu/drm/amd/powerplay/smu_v12_0.c b/drivers/gpu/drm/amd/powerplay/smu_v12_0.c
index f10113fc4571..5b56e7579ff4 100644
--- a/drivers/gpu/drm/amd/powerplay/smu_v12_0.c
+++ b/drivers/gpu/drm/amd/powerplay/smu_v12_0.c
@@ -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;
 
-- 
2.27.0

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH 1/2] drm/amd/powerplay: drop redundant .set_min_dcefclk_deep_sleep API
  2020-06-09 10:09 [PATCH 1/2] drm/amd/powerplay: drop redundant .set_min_dcefclk_deep_sleep API Evan Quan
  2020-06-09 10:09 ` [PATCH 2/2] drm/amd/powerplay: drop unnecessary wrapper .populate_smc_tables Evan Quan
@ 2020-06-09 19:49 ` Alex Deucher
  1 sibling, 0 replies; 4+ messages in thread
From: Alex Deucher @ 2020-06-09 19:49 UTC (permalink / raw)
  To: Evan Quan; +Cc: Deucher, Alexander, amd-gfx list

On Tue, Jun 9, 2020 at 6:10 AM Evan Quan <evan.quan@amd.com> wrote:
>
> It has exactly the same functionality as .set_deep_sleep_dcefclk.
>
> Change-Id: Ib4d2d604ca014e194cb2b61ac770e4370ecad74d
> Signed-off-by: Evan Quan <evan.quan@amd.com>
> ---
>  drivers/gpu/drm/amd/powerplay/amdgpu_smu.c         | 11 +++++------
>  drivers/gpu/drm/amd/powerplay/arcturus_ppt.c       |  3 +--
>  drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h     |  1 -
>  drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h      |  2 --
>  drivers/gpu/drm/amd/powerplay/navi10_ppt.c         |  1 -
>  drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c |  3 +--
>  drivers/gpu/drm/amd/powerplay/smu_internal.h       |  4 ++--
>  drivers/gpu/drm/amd/powerplay/smu_v11_0.c          | 10 ----------
>  8 files changed, 9 insertions(+), 26 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
> index 6beae3b496be..89dd12536d58 100644
> --- a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
> +++ b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
> @@ -1269,7 +1269,8 @@ static int smu_smc_hw_setup(struct smu_context *smu)
>          * Set min deep sleep dce fclk with bootup value from vbios via
>          * SetMinDeepSleepDcefclk MSG.
>          */
> -       ret = smu_set_min_dcef_deep_sleep(smu);
> +       ret = smu_set_min_dcef_deep_sleep(smu,
> +                                         smu->smu_table.boot_values.dcefclk / 100);
>         if (ret)
>                 return ret;
>
> @@ -1584,9 +1585,8 @@ int smu_display_configuration_change(struct smu_context *smu,
>
>         mutex_lock(&smu->mutex);
>
> -       if (smu->ppt_funcs->set_deep_sleep_dcefclk)
> -               smu->ppt_funcs->set_deep_sleep_dcefclk(smu,
> -                               display_config->min_dcef_deep_sleep_set_clk / 100);
> +       smu_set_min_dcef_deep_sleep(smu,
> +                                   display_config->min_dcef_deep_sleep_set_clk / 100);
>
>         for (index = 0; index < display_config->num_path_including_non_display; index++) {
>                 if (display_config->displays[index].controller_id != 0)
> @@ -2482,8 +2482,7 @@ int smu_set_deep_sleep_dcefclk(struct smu_context *smu, int clk)
>
>         mutex_lock(&smu->mutex);
>
> -       if (smu->ppt_funcs->set_deep_sleep_dcefclk)
> -               ret = smu->ppt_funcs->set_deep_sleep_dcefclk(smu, clk);
> +       ret = smu_set_min_dcef_deep_sleep(smu, clk);
>
>         mutex_unlock(&smu->mutex);
>
> diff --git a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
> index c104844b28f1..96c9a348f8b3 100644
> --- a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
> +++ b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
> @@ -2590,7 +2590,6 @@ static const struct pptable_funcs arcturus_ppt_funcs = {
>         .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_min_dcef_deep_sleep = NULL,
>         .set_driver_table_location = smu_v11_0_set_driver_table_location,
>         .set_tool_table_location = smu_v11_0_set_tool_table_location,
>         .notify_memory_pool_location = smu_v11_0_notify_memory_pool_location,
> @@ -2605,7 +2604,7 @@ static const struct pptable_funcs arcturus_ppt_funcs = {
>         .init_max_sustainable_clocks = smu_v11_0_init_max_sustainable_clocks,
>         .enable_thermal_alert = smu_v11_0_enable_thermal_alert,
>         .disable_thermal_alert = smu_v11_0_disable_thermal_alert,
> -       .set_deep_sleep_dcefclk = smu_v11_0_set_deep_sleep_dcefclk,
> +       .set_deep_sleep_dcefclk = NULL,
>         .display_clock_voltage_request = smu_v11_0_display_clock_voltage_request,
>         .get_fan_control_mode = smu_v11_0_get_fan_control_mode,
>         .set_fan_control_mode = smu_v11_0_set_fan_control_mode,
> diff --git a/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h b/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
> index 8eaa6338ad44..3420a58fad03 100644
> --- a/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
> +++ b/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
> @@ -510,7 +510,6 @@ struct pptable_funcs {
>         int (*powergate_sdma)(struct smu_context *smu, bool gate);
>         int (*set_gfx_cgpg)(struct smu_context *smu, bool enable);
>         int (*write_pptable)(struct smu_context *smu);
> -       int (*set_min_dcef_deep_sleep)(struct smu_context *smu);
>         int (*set_driver_table_location)(struct smu_context *smu);
>         int (*set_tool_table_location)(struct smu_context *smu);
>         int (*notify_memory_pool_location)(struct smu_context *smu);
> diff --git a/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h b/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
> index 2e9939beb128..9ccf62e99dcb 100644
> --- a/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
> +++ b/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
> @@ -170,8 +170,6 @@ int smu_v11_0_check_fw_version(struct smu_context *smu);
>
>  int smu_v11_0_write_pptable(struct smu_context *smu);
>
> -int smu_v11_0_set_min_dcef_deep_sleep(struct smu_context *smu);
> -
>  int smu_v11_0_set_driver_table_location(struct smu_context *smu);
>
>  int smu_v11_0_set_tool_table_location(struct smu_context *smu);
> diff --git a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c b/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
> index 115794557190..abbfcce6d9ad 100644
> --- a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
> +++ b/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
> @@ -2426,7 +2426,6 @@ static const struct pptable_funcs navi10_ppt_funcs = {
>         .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_min_dcef_deep_sleep = smu_v11_0_set_min_dcef_deep_sleep,
>         .set_driver_table_location = smu_v11_0_set_driver_table_location,
>         .set_tool_table_location = smu_v11_0_set_tool_table_location,
>         .notify_memory_pool_location = smu_v11_0_notify_memory_pool_location,
> diff --git a/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c b/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
> index 81cc04de9b06..6a9d04cac240 100644
> --- a/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
> +++ b/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
> @@ -2596,7 +2596,6 @@ static const struct pptable_funcs sienna_cichlid_ppt_funcs = {
>         .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_min_dcef_deep_sleep = NULL,
>         .set_driver_table_location = smu_v11_0_set_driver_table_location,
>         .set_tool_table_location = smu_v11_0_set_tool_table_location,
>         .notify_memory_pool_location = smu_v11_0_notify_memory_pool_location,
> @@ -2611,7 +2610,7 @@ static const struct pptable_funcs sienna_cichlid_ppt_funcs = {
>         .init_max_sustainable_clocks = smu_v11_0_init_max_sustainable_clocks,
>         .enable_thermal_alert = smu_v11_0_enable_thermal_alert,
>         .disable_thermal_alert = smu_v11_0_disable_thermal_alert,
> -       .set_deep_sleep_dcefclk = smu_v11_0_set_deep_sleep_dcefclk,
> +       .set_deep_sleep_dcefclk = NULL,
>         .display_clock_voltage_request = smu_v11_0_display_clock_voltage_request,
>         .get_fan_control_mode = smu_v11_0_get_fan_control_mode,
>         .set_fan_control_mode = smu_v11_0_set_fan_control_mode,
> diff --git a/drivers/gpu/drm/amd/powerplay/smu_internal.h b/drivers/gpu/drm/amd/powerplay/smu_internal.h
> index 094db34ddbd1..86c09098963a 100644
> --- a/drivers/gpu/drm/amd/powerplay/smu_internal.h
> +++ b/drivers/gpu/drm/amd/powerplay/smu_internal.h
> @@ -51,8 +51,8 @@
>         ((smu)->ppt_funcs->check_fw_version ? (smu)->ppt_funcs->check_fw_version((smu)) : 0)
>  #define smu_write_pptable(smu) \
>         ((smu)->ppt_funcs->write_pptable ? (smu)->ppt_funcs->write_pptable((smu)) : 0)
> -#define smu_set_min_dcef_deep_sleep(smu) \
> -       ((smu)->ppt_funcs->set_min_dcef_deep_sleep ? (smu)->ppt_funcs->set_min_dcef_deep_sleep((smu)) : 0)
> +#define smu_set_min_dcef_deep_sleep(smu, clk) \
> +       ((smu)->ppt_funcs->set_deep_sleep_dcefclk ? (smu)->ppt_funcs->set_deep_sleep_dcefclk((smu), (clk)) : 0)

Can you make the callback and macro names match?  E.g.,

 +#define smu_set_min_dcef_deep_sleep(smu, clk) \
 +       ((smu)->ppt_funcs->set_min_dcef_deep_sleep ?
(smu)->ppt_funcs->set_min_dcef_deep_sleep((smu), (clk)) : 0)

That makes it easier to trace the macro back to it's callback.  With that fixed:
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>

Alex

>  #define smu_set_driver_table_location(smu) \
>         ((smu)->ppt_funcs->set_driver_table_location ? (smu)->ppt_funcs->set_driver_table_location((smu)) : 0)
>  #define smu_set_tool_table_location(smu) \
> diff --git a/drivers/gpu/drm/amd/powerplay/smu_v11_0.c b/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
> index 06e3799aa923..5590dab46e8c 100644
> --- a/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
> +++ b/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
> @@ -782,16 +782,6 @@ int smu_v11_0_set_deep_sleep_dcefclk(struct smu_context *smu, uint32_t clk)
>         return ret;
>  }
>
> -int smu_v11_0_set_min_dcef_deep_sleep(struct smu_context *smu)
> -{
> -       struct smu_table_context *table_context = &smu->smu_table;
> -
> -       if (!table_context)
> -               return -EINVAL;
> -
> -       return smu_v11_0_set_deep_sleep_dcefclk(smu, table_context->boot_values.dcefclk / 100);
> -}
> -
>  int smu_v11_0_set_driver_table_location(struct smu_context *smu)
>  {
>         struct smu_table *driver_table = &smu->smu_table.driver_table;
> --
> 2.27.0
>
> _______________________________________________
> amd-gfx mailing list
> amd-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH 2/2] drm/amd/powerplay: drop unnecessary wrapper .populate_smc_tables
  2020-06-09 10:09 ` [PATCH 2/2] drm/amd/powerplay: drop unnecessary wrapper .populate_smc_tables Evan Quan
@ 2020-06-09 19:51   ` Alex Deucher
  0 siblings, 0 replies; 4+ messages in thread
From: Alex Deucher @ 2020-06-09 19:51 UTC (permalink / raw)
  To: Evan Quan; +Cc: Deucher, Alexander, amd-gfx list

On Tue, Jun 9, 2020 at 6:10 AM Evan Quan <evan.quan@amd.com> wrote:
>
> Since .populate_smc_tables is just a wrapper of .set_default_dpm_table.
>
> Change-Id: I80e89146359d6cf5d80f1887878d371b41b41cb0
> Signed-off-by: Evan Quan <evan.quan@amd.com>

Reviewed-by: Alex Deucher <alexander.deucher@amd.com>

> ---
>  drivers/gpu/drm/amd/powerplay/amdgpu_smu.c         | 2 +-
>  drivers/gpu/drm/amd/powerplay/arcturus_ppt.c       | 1 -
>  drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h     | 1 -
>  drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h      | 2 --
>  drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h      | 2 +-
>  drivers/gpu/drm/amd/powerplay/navi10_ppt.c         | 1 -
>  drivers/gpu/drm/amd/powerplay/renoir_ppt.c         | 2 +-
>  drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c | 1 -
>  drivers/gpu/drm/amd/powerplay/smu_internal.h       | 2 --
>  drivers/gpu/drm/amd/powerplay/smu_v11_0.c          | 9 ---------
>  drivers/gpu/drm/amd/powerplay/smu_v12_0.c          | 2 +-
>  11 files changed, 4 insertions(+), 21 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
> index 89dd12536d58..78263de02678 100644
> --- a/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
> +++ b/drivers/gpu/drm/amd/powerplay/amdgpu_smu.c
> @@ -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;
> diff --git a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
> index 96c9a348f8b3..ee492fc77414 100644
> --- a/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
> +++ b/drivers/gpu/drm/amd/powerplay/arcturus_ppt.c
> @@ -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,
> diff --git a/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h b/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
> index 3420a58fad03..0d1429fc791b 100644
> --- a/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
> +++ b/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h
> @@ -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);
> diff --git a/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h b/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
> index 9ccf62e99dcb..d6cd3d74dcfa 100644
> --- a/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
> +++ b/drivers/gpu/drm/amd/powerplay/inc/smu_v11_0.h
> @@ -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);
> diff --git a/drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h b/drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h
> index 7fbebc1979cf..d29f75223987 100644
> --- a/drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h
> +++ b/drivers/gpu/drm/amd/powerplay/inc/smu_v12_0.h
> @@ -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);
> diff --git a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c b/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
> index abbfcce6d9ad..ef04ab1eba94 100644
> --- a/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
> +++ b/drivers/gpu/drm/amd/powerplay/navi10_ppt.c
> @@ -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,
> diff --git a/drivers/gpu/drm/amd/powerplay/renoir_ppt.c b/drivers/gpu/drm/amd/powerplay/renoir_ppt.c
> index 6b5e60b4c039..f286c1e1934f 100644
> --- a/drivers/gpu/drm/amd/powerplay/renoir_ppt.c
> +++ b/drivers/gpu/drm/amd/powerplay/renoir_ppt.c
> @@ -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,
> diff --git a/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c b/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
> index 6a9d04cac240..9a05fda05355 100644
> --- a/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
> +++ b/drivers/gpu/drm/amd/powerplay/sienna_cichlid_ppt.c
> @@ -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,
> diff --git a/drivers/gpu/drm/amd/powerplay/smu_internal.h b/drivers/gpu/drm/amd/powerplay/smu_internal.h
> index 86c09098963a..03679eb21e0d 100644
> --- a/drivers/gpu/drm/amd/powerplay/smu_internal.h
> +++ b/drivers/gpu/drm/amd/powerplay/smu_internal.h
> @@ -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) \
> diff --git a/drivers/gpu/drm/amd/powerplay/smu_v11_0.c b/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
> index 5590dab46e8c..9e3fee9e4aca 100644
> --- a/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
> +++ b/drivers/gpu/drm/amd/powerplay/smu_v11_0.c
> @@ -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;
> diff --git a/drivers/gpu/drm/amd/powerplay/smu_v12_0.c b/drivers/gpu/drm/amd/powerplay/smu_v12_0.c
> index f10113fc4571..5b56e7579ff4 100644
> --- a/drivers/gpu/drm/amd/powerplay/smu_v12_0.c
> +++ b/drivers/gpu/drm/amd/powerplay/smu_v12_0.c
> @@ -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;
>
> --
> 2.27.0
>
> _______________________________________________
> amd-gfx mailing list
> amd-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-06-09 19:51 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-09 10:09 [PATCH 1/2] drm/amd/powerplay: drop redundant .set_min_dcefclk_deep_sleep API Evan Quan
2020-06-09 10:09 ` [PATCH 2/2] drm/amd/powerplay: drop unnecessary wrapper .populate_smc_tables Evan Quan
2020-06-09 19:51   ` Alex Deucher
2020-06-09 19:49 ` [PATCH 1/2] drm/amd/powerplay: drop redundant .set_min_dcefclk_deep_sleep API Alex Deucher

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.