* [PATCH] drm/amd/powerplay: delete pp dead code on raven
@ 2017-08-25 10:18 Rex Zhu
[not found] ` <1503656288-15474-1-git-send-email-Rex.Zhu-5C7GfCeVMHo@public.gmane.org>
0 siblings, 1 reply; 3+ messages in thread
From: Rex Zhu @ 2017-08-25 10:18 UTC (permalink / raw)
To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW; +Cc: Rex Zhu
Change-Id: Ib2a3cd06c540a90eb33fc9e4ce0f3122c5f2c0d3
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
---
drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c | 66 --------------------------
1 file changed, 66 deletions(-)
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c
index a5fa546..ebbee5f 100644
--- a/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c
+++ b/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c
@@ -49,29 +49,6 @@
int rv_display_clock_voltage_request(struct pp_hwmgr *hwmgr,
struct pp_display_clock_request *clock_req);
-struct phm_vq_budgeting_record rv_vqtable[] = {
-/* CUs, SSP low, SSP High, Display Configuration, AWD/non-AWD,
- * Sustainable GFXCLK, Sustainable FCLK, Sustainable CUs,
- * unused, unused, unused
- */
- { 11, 30, 60, VQ_DisplayConfig_NoneAWD, 80000, 160000, 11, 0, 0, 0 },
- { 11, 30, 60, VQ_DisplayConfig_AWD, 80000, 160000, 11, 0, 0, 0 },
-
- { 8, 30, 60, VQ_DisplayConfig_NoneAWD, 100000, 160000, 8, 0, 0, 0 },
- { 8, 30, 60, VQ_DisplayConfig_AWD, 100000, 160000, 8, 0, 0, 0 },
-
- { 10, 12, 30, VQ_DisplayConfig_NoneAWD, 40000, 120000, 10, 0, 0, 0 },
- { 10, 12, 30, VQ_DisplayConfig_AWD, 40000, 120000, 10, 0, 0, 0 },
-
- { 8, 12, 30, VQ_DisplayConfig_NoneAWD, 45000, 120000, 8, 0, 0, 0 },
- { 8, 12, 30, VQ_DisplayConfig_AWD, 45000, 120000, 8, 0, 0, 0 },
-
- { 6, 12, 30, VQ_DisplayConfig_NoneAWD, 45000, 120000, 6, 0, 0, 0 },
- { 6, 12, 30, VQ_DisplayConfig_AWD, 45000, 120000, 6, 0, 0, 0 },
-
- { 3, 12, 30, VQ_DisplayConfig_NoneAWD, 45000, 120000, 3, 0, 0, 0 },
- { 3, 12, 30, VQ_DisplayConfig_AWD, 45000, 120000, 3, 0, 0, 0 },
-};
static struct rv_power_state *cast_rv_ps(struct pp_hw_power_state *hw_ps)
{
@@ -90,42 +67,6 @@ static const struct rv_power_state *cast_const_rv_ps(
return (struct rv_power_state *)hw_ps;
}
-static int rv_init_vq_budget_table(struct pp_hwmgr *hwmgr)
-{
- uint32_t table_size, i;
- struct phm_vq_budgeting_table *ptable;
- uint32_t num_entries = ARRAY_SIZE(rv_vqtable);
-
- if (hwmgr->dyn_state.vq_budgeting_table != NULL)
- return 0;
-
- table_size = sizeof(struct phm_vq_budgeting_table) +
- sizeof(struct phm_vq_budgeting_record) * (num_entries - 1);
-
- ptable = kzalloc(table_size, GFP_KERNEL);
- if (NULL == ptable)
- return -ENOMEM;
-
- ptable->numEntries = (uint8_t) num_entries;
-
- for (i = 0; i < ptable->numEntries; i++) {
- ptable->entries[i].ulCUs = rv_vqtable[i].ulCUs;
- ptable->entries[i].ulSustainableSOCPowerLimitLow = rv_vqtable[i].ulSustainableSOCPowerLimitLow;
- ptable->entries[i].ulSustainableSOCPowerLimitHigh = rv_vqtable[i].ulSustainableSOCPowerLimitHigh;
- ptable->entries[i].ulMinSclkLow = rv_vqtable[i].ulMinSclkLow;
- ptable->entries[i].ulMinSclkHigh = rv_vqtable[i].ulMinSclkHigh;
- ptable->entries[i].ucDispConfig = rv_vqtable[i].ucDispConfig;
- ptable->entries[i].ulDClk = rv_vqtable[i].ulDClk;
- ptable->entries[i].ulEClk = rv_vqtable[i].ulEClk;
- ptable->entries[i].ulSustainableSclk = rv_vqtable[i].ulSustainableSclk;
- ptable->entries[i].ulSustainableCUs = rv_vqtable[i].ulSustainableCUs;
- }
-
- hwmgr->dyn_state.vq_budgeting_table = ptable;
-
- return 0;
-}
-
static int rv_initialize_dpm_defaults(struct pp_hwmgr *hwmgr)
{
struct rv_hwmgr *rv_hwmgr = (struct rv_hwmgr *)(hwmgr->backend);
@@ -589,8 +530,6 @@ static int rv_hwmgr_backend_init(struct pp_hwmgr *hwmgr)
hwmgr->platform_descriptor.minimumClocksReductionPercentage = 50;
- rv_init_vq_budget_table(hwmgr);
-
return result;
}
@@ -635,11 +574,6 @@ static int rv_hwmgr_backend_fini(struct pp_hwmgr *hwmgr)
hwmgr->dyn_state.vddc_dep_on_dal_pwrl = NULL;
}
- if (NULL != hwmgr->dyn_state.vq_budgeting_table) {
- kfree(hwmgr->dyn_state.vq_budgeting_table);
- hwmgr->dyn_state.vq_budgeting_table = NULL;
- }
-
kfree(hwmgr->backend);
hwmgr->backend = NULL;
--
1.9.1
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
^ permalink raw reply related [flat|nested] 3+ messages in thread
* RE: [PATCH] drm/amd/powerplay: delete pp dead code on raven
[not found] ` <1503656288-15474-1-git-send-email-Rex.Zhu-5C7GfCeVMHo@public.gmane.org>
@ 2017-08-25 10:34 ` Zhang, Hawking
2017-08-25 14:45 ` Alex Deucher
1 sibling, 0 replies; 3+ messages in thread
From: Zhang, Hawking @ 2017-08-25 10:34 UTC (permalink / raw)
To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW; +Cc: Zhu, Rex
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Regards,
Hawking
-----Original Message-----
From: amd-gfx [mailto:amd-gfx-bounces@lists.freedesktop.org] On Behalf Of Rex Zhu
Sent: Friday, August 25, 2017 18:18
To: amd-gfx@lists.freedesktop.org
Cc: Zhu, Rex <Rex.Zhu@amd.com>
Subject: [PATCH] drm/amd/powerplay: delete pp dead code on raven
Change-Id: Ib2a3cd06c540a90eb33fc9e4ce0f3122c5f2c0d3
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
---
drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c | 66 --------------------------
1 file changed, 66 deletions(-)
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c
index a5fa546..ebbee5f 100644
--- a/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c
+++ b/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c
@@ -49,29 +49,6 @@
int rv_display_clock_voltage_request(struct pp_hwmgr *hwmgr,
struct pp_display_clock_request *clock_req);
-struct phm_vq_budgeting_record rv_vqtable[] = {
-/* CUs, SSP low, SSP High, Display Configuration, AWD/non-AWD,
- * Sustainable GFXCLK, Sustainable FCLK, Sustainable CUs,
- * unused, unused, unused
- */
- { 11, 30, 60, VQ_DisplayConfig_NoneAWD, 80000, 160000, 11, 0, 0, 0 },
- { 11, 30, 60, VQ_DisplayConfig_AWD, 80000, 160000, 11, 0, 0, 0 },
-
- { 8, 30, 60, VQ_DisplayConfig_NoneAWD, 100000, 160000, 8, 0, 0, 0 },
- { 8, 30, 60, VQ_DisplayConfig_AWD, 100000, 160000, 8, 0, 0, 0 },
-
- { 10, 12, 30, VQ_DisplayConfig_NoneAWD, 40000, 120000, 10, 0, 0, 0 },
- { 10, 12, 30, VQ_DisplayConfig_AWD, 40000, 120000, 10, 0, 0, 0 },
-
- { 8, 12, 30, VQ_DisplayConfig_NoneAWD, 45000, 120000, 8, 0, 0, 0 },
- { 8, 12, 30, VQ_DisplayConfig_AWD, 45000, 120000, 8, 0, 0, 0 },
-
- { 6, 12, 30, VQ_DisplayConfig_NoneAWD, 45000, 120000, 6, 0, 0, 0 },
- { 6, 12, 30, VQ_DisplayConfig_AWD, 45000, 120000, 6, 0, 0, 0 },
-
- { 3, 12, 30, VQ_DisplayConfig_NoneAWD, 45000, 120000, 3, 0, 0, 0 },
- { 3, 12, 30, VQ_DisplayConfig_AWD, 45000, 120000, 3, 0, 0, 0 },
-};
static struct rv_power_state *cast_rv_ps(struct pp_hw_power_state *hw_ps) { @@ -90,42 +67,6 @@ static const struct rv_power_state *cast_const_rv_ps(
return (struct rv_power_state *)hw_ps; }
-static int rv_init_vq_budget_table(struct pp_hwmgr *hwmgr) -{
- uint32_t table_size, i;
- struct phm_vq_budgeting_table *ptable;
- uint32_t num_entries = ARRAY_SIZE(rv_vqtable);
-
- if (hwmgr->dyn_state.vq_budgeting_table != NULL)
- return 0;
-
- table_size = sizeof(struct phm_vq_budgeting_table) +
- sizeof(struct phm_vq_budgeting_record) * (num_entries - 1);
-
- ptable = kzalloc(table_size, GFP_KERNEL);
- if (NULL == ptable)
- return -ENOMEM;
-
- ptable->numEntries = (uint8_t) num_entries;
-
- for (i = 0; i < ptable->numEntries; i++) {
- ptable->entries[i].ulCUs = rv_vqtable[i].ulCUs;
- ptable->entries[i].ulSustainableSOCPowerLimitLow = rv_vqtable[i].ulSustainableSOCPowerLimitLow;
- ptable->entries[i].ulSustainableSOCPowerLimitHigh = rv_vqtable[i].ulSustainableSOCPowerLimitHigh;
- ptable->entries[i].ulMinSclkLow = rv_vqtable[i].ulMinSclkLow;
- ptable->entries[i].ulMinSclkHigh = rv_vqtable[i].ulMinSclkHigh;
- ptable->entries[i].ucDispConfig = rv_vqtable[i].ucDispConfig;
- ptable->entries[i].ulDClk = rv_vqtable[i].ulDClk;
- ptable->entries[i].ulEClk = rv_vqtable[i].ulEClk;
- ptable->entries[i].ulSustainableSclk = rv_vqtable[i].ulSustainableSclk;
- ptable->entries[i].ulSustainableCUs = rv_vqtable[i].ulSustainableCUs;
- }
-
- hwmgr->dyn_state.vq_budgeting_table = ptable;
-
- return 0;
-}
-
static int rv_initialize_dpm_defaults(struct pp_hwmgr *hwmgr) {
struct rv_hwmgr *rv_hwmgr = (struct rv_hwmgr *)(hwmgr->backend); @@ -589,8 +530,6 @@ static int rv_hwmgr_backend_init(struct pp_hwmgr *hwmgr)
hwmgr->platform_descriptor.minimumClocksReductionPercentage = 50;
- rv_init_vq_budget_table(hwmgr);
-
return result;
}
@@ -635,11 +574,6 @@ static int rv_hwmgr_backend_fini(struct pp_hwmgr *hwmgr)
hwmgr->dyn_state.vddc_dep_on_dal_pwrl = NULL;
}
- if (NULL != hwmgr->dyn_state.vq_budgeting_table) {
- kfree(hwmgr->dyn_state.vq_budgeting_table);
- hwmgr->dyn_state.vq_budgeting_table = NULL;
- }
-
kfree(hwmgr->backend);
hwmgr->backend = NULL;
--
1.9.1
_______________________________________________
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 related [flat|nested] 3+ messages in thread
* Re: [PATCH] drm/amd/powerplay: delete pp dead code on raven
[not found] ` <1503656288-15474-1-git-send-email-Rex.Zhu-5C7GfCeVMHo@public.gmane.org>
2017-08-25 10:34 ` Zhang, Hawking
@ 2017-08-25 14:45 ` Alex Deucher
1 sibling, 0 replies; 3+ messages in thread
From: Alex Deucher @ 2017-08-25 14:45 UTC (permalink / raw)
To: Rex Zhu; +Cc: amd-gfx list
On Fri, Aug 25, 2017 at 6:18 AM, Rex Zhu <Rex.Zhu@amd.com> wrote:
> Change-Id: Ib2a3cd06c540a90eb33fc9e4ce0f3122c5f2c0d3
> Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
> ---
> drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c | 66 --------------------------
> 1 file changed, 66 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c
> index a5fa546..ebbee5f 100644
> --- a/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c
> +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/rv_hwmgr.c
> @@ -49,29 +49,6 @@
> int rv_display_clock_voltage_request(struct pp_hwmgr *hwmgr,
> struct pp_display_clock_request *clock_req);
>
> -struct phm_vq_budgeting_record rv_vqtable[] = {
> -/* CUs, SSP low, SSP High, Display Configuration, AWD/non-AWD,
> - * Sustainable GFXCLK, Sustainable FCLK, Sustainable CUs,
> - * unused, unused, unused
> - */
> - { 11, 30, 60, VQ_DisplayConfig_NoneAWD, 80000, 160000, 11, 0, 0, 0 },
> - { 11, 30, 60, VQ_DisplayConfig_AWD, 80000, 160000, 11, 0, 0, 0 },
> -
> - { 8, 30, 60, VQ_DisplayConfig_NoneAWD, 100000, 160000, 8, 0, 0, 0 },
> - { 8, 30, 60, VQ_DisplayConfig_AWD, 100000, 160000, 8, 0, 0, 0 },
> -
> - { 10, 12, 30, VQ_DisplayConfig_NoneAWD, 40000, 120000, 10, 0, 0, 0 },
> - { 10, 12, 30, VQ_DisplayConfig_AWD, 40000, 120000, 10, 0, 0, 0 },
> -
> - { 8, 12, 30, VQ_DisplayConfig_NoneAWD, 45000, 120000, 8, 0, 0, 0 },
> - { 8, 12, 30, VQ_DisplayConfig_AWD, 45000, 120000, 8, 0, 0, 0 },
> -
> - { 6, 12, 30, VQ_DisplayConfig_NoneAWD, 45000, 120000, 6, 0, 0, 0 },
> - { 6, 12, 30, VQ_DisplayConfig_AWD, 45000, 120000, 6, 0, 0, 0 },
> -
> - { 3, 12, 30, VQ_DisplayConfig_NoneAWD, 45000, 120000, 3, 0, 0, 0 },
> - { 3, 12, 30, VQ_DisplayConfig_AWD, 45000, 120000, 3, 0, 0, 0 },
> -};
>
> static struct rv_power_state *cast_rv_ps(struct pp_hw_power_state *hw_ps)
> {
> @@ -90,42 +67,6 @@ static const struct rv_power_state *cast_const_rv_ps(
> return (struct rv_power_state *)hw_ps;
> }
>
> -static int rv_init_vq_budget_table(struct pp_hwmgr *hwmgr)
> -{
> - uint32_t table_size, i;
> - struct phm_vq_budgeting_table *ptable;
> - uint32_t num_entries = ARRAY_SIZE(rv_vqtable);
> -
> - if (hwmgr->dyn_state.vq_budgeting_table != NULL)
> - return 0;
> -
> - table_size = sizeof(struct phm_vq_budgeting_table) +
> - sizeof(struct phm_vq_budgeting_record) * (num_entries - 1);
> -
> - ptable = kzalloc(table_size, GFP_KERNEL);
> - if (NULL == ptable)
> - return -ENOMEM;
> -
> - ptable->numEntries = (uint8_t) num_entries;
> -
> - for (i = 0; i < ptable->numEntries; i++) {
> - ptable->entries[i].ulCUs = rv_vqtable[i].ulCUs;
> - ptable->entries[i].ulSustainableSOCPowerLimitLow = rv_vqtable[i].ulSustainableSOCPowerLimitLow;
> - ptable->entries[i].ulSustainableSOCPowerLimitHigh = rv_vqtable[i].ulSustainableSOCPowerLimitHigh;
> - ptable->entries[i].ulMinSclkLow = rv_vqtable[i].ulMinSclkLow;
> - ptable->entries[i].ulMinSclkHigh = rv_vqtable[i].ulMinSclkHigh;
> - ptable->entries[i].ucDispConfig = rv_vqtable[i].ucDispConfig;
> - ptable->entries[i].ulDClk = rv_vqtable[i].ulDClk;
> - ptable->entries[i].ulEClk = rv_vqtable[i].ulEClk;
> - ptable->entries[i].ulSustainableSclk = rv_vqtable[i].ulSustainableSclk;
> - ptable->entries[i].ulSustainableCUs = rv_vqtable[i].ulSustainableCUs;
> - }
> -
> - hwmgr->dyn_state.vq_budgeting_table = ptable;
> -
> - return 0;
> -}
> -
> static int rv_initialize_dpm_defaults(struct pp_hwmgr *hwmgr)
> {
> struct rv_hwmgr *rv_hwmgr = (struct rv_hwmgr *)(hwmgr->backend);
> @@ -589,8 +530,6 @@ static int rv_hwmgr_backend_init(struct pp_hwmgr *hwmgr)
>
> hwmgr->platform_descriptor.minimumClocksReductionPercentage = 50;
>
> - rv_init_vq_budget_table(hwmgr);
> -
> return result;
> }
>
> @@ -635,11 +574,6 @@ static int rv_hwmgr_backend_fini(struct pp_hwmgr *hwmgr)
> hwmgr->dyn_state.vddc_dep_on_dal_pwrl = NULL;
> }
>
> - if (NULL != hwmgr->dyn_state.vq_budgeting_table) {
> - kfree(hwmgr->dyn_state.vq_budgeting_table);
> - hwmgr->dyn_state.vq_budgeting_table = NULL;
> - }
> -
> kfree(hwmgr->backend);
> hwmgr->backend = NULL;
>
> --
> 1.9.1
>
> _______________________________________________
> 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] 3+ messages in thread
end of thread, other threads:[~2017-08-25 14:45 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-25 10:18 [PATCH] drm/amd/powerplay: delete pp dead code on raven Rex Zhu
[not found] ` <1503656288-15474-1-git-send-email-Rex.Zhu-5C7GfCeVMHo@public.gmane.org>
2017-08-25 10:34 ` Zhang, Hawking
2017-08-25 14:45 ` 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.