All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/amd/powerplay: disable engine spread spectrum feature on Vega10.
@ 2017-05-04  3:33 Rex Zhu
       [not found] ` <1493868804-794-1-git-send-email-Rex.Zhu-5C7GfCeVMHo@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Rex Zhu @ 2017-05-04  3:33 UTC (permalink / raw)
  To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW; +Cc: Rex Zhu

Vega10 atomfirmware do not have ASIC_InternalSS_Info table
so disable this feature by default in driver.

Change-Id: I2ef2c668fb41fc6c6f448c7c0f1812baf8e7b375
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
---
 drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
index 8baa890..e24e54c 100644
--- a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
+++ b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
@@ -1535,7 +1535,11 @@ static int vega10_populate_single_gfx_level(struct pp_hwmgr *hwmgr,
 	current_gfxclk_level->FbMult =
 			cpu_to_le32(dividers.ulPll_fb_mult);
 	/* Spread FB Multiplier bit: bit 0:8 int, bit 31:16 frac */
-	current_gfxclk_level->SsOn = dividers.ucPll_ss_enable;
+	if (phm_cap_enabled(hwmgr->platform_descriptor.platformCaps,
+				PHM_PlatformCaps_EngineSpreadSpectrumSupport))
+		current_gfxclk_level->SsOn = dividers.ucPll_ss_enable;
+	else
+		current_gfxclk_level->SsOn = 0;
 	current_gfxclk_level->SsFbMult =
 			cpu_to_le32(dividers.ulPll_ss_fbsmult);
 	current_gfxclk_level->SsSlewFrac =
-- 
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: disable engine spread spectrum feature on Vega10.
       [not found] ` <1493868804-794-1-git-send-email-Rex.Zhu-5C7GfCeVMHo@public.gmane.org>
@ 2017-05-04  3:48   ` Wang, Ken
  2017-05-04  3:52   ` Deucher, Alexander
  1 sibling, 0 replies; 3+ messages in thread
From: Wang, Ken @ 2017-05-04  3:48 UTC (permalink / raw)
  To: Zhu, Rex, amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW


[-- Attachment #1.1: Type: text/plain, Size: 2033 bytes --]

Reviewed-by: Ken Wang <Qingqing.Wang-5C7GfCeVMHo@public.gmane.org>

________________________________
From: amd-gfx <amd-gfx-bounces-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org> on behalf of Rex Zhu <Rex.Zhu-5C7GfCeVMHo@public.gmane.org>
Sent: Thursday, May 4, 2017 11:33:24 AM
To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Cc: Zhu, Rex
Subject: [PATCH] drm/amd/powerplay: disable engine spread spectrum feature on Vega10.

Vega10 atomfirmware do not have ASIC_InternalSS_Info table
so disable this feature by default in driver.

Change-Id: I2ef2c668fb41fc6c6f448c7c0f1812baf8e7b375
Signed-off-by: Rex Zhu <Rex.Zhu-5C7GfCeVMHo@public.gmane.org>
---
 drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
index 8baa890..e24e54c 100644
--- a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
+++ b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
@@ -1535,7 +1535,11 @@ static int vega10_populate_single_gfx_level(struct pp_hwmgr *hwmgr,
         current_gfxclk_level->FbMult =
                         cpu_to_le32(dividers.ulPll_fb_mult);
         /* Spread FB Multiplier bit: bit 0:8 int, bit 31:16 frac */
-       current_gfxclk_level->SsOn = dividers.ucPll_ss_enable;
+       if (phm_cap_enabled(hwmgr->platform_descriptor.platformCaps,
+                               PHM_PlatformCaps_EngineSpreadSpectrumSupport))
+               current_gfxclk_level->SsOn = dividers.ucPll_ss_enable;
+       else
+               current_gfxclk_level->SsOn = 0;
         current_gfxclk_level->SsFbMult =
                         cpu_to_le32(dividers.ulPll_ss_fbsmult);
         current_gfxclk_level->SsSlewFrac =
--
1.9.1

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

[-- Attachment #1.2: Type: text/html, Size: 4075 bytes --]

[-- Attachment #2: Type: text/plain, Size: 154 bytes --]

_______________________________________________
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: disable engine spread spectrum feature on Vega10.
       [not found] ` <1493868804-794-1-git-send-email-Rex.Zhu-5C7GfCeVMHo@public.gmane.org>
  2017-05-04  3:48   ` Wang, Ken
@ 2017-05-04  3:52   ` Deucher, Alexander
  1 sibling, 0 replies; 3+ messages in thread
From: Deucher, Alexander @ 2017-05-04  3:52 UTC (permalink / raw)
  To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW; +Cc: Zhu, Rex

> -----Original Message-----
> From: amd-gfx [mailto:amd-gfx-bounces@lists.freedesktop.org] On Behalf
> Of Rex Zhu
> Sent: Wednesday, May 03, 2017 11:33 PM
> To: amd-gfx@lists.freedesktop.org
> Cc: Zhu, Rex
> Subject: [PATCH] drm/amd/powerplay: disable engine spread spectrum
> feature on Vega10.
> 
> Vega10 atomfirmware do not have ASIC_InternalSS_Info table
> so disable this feature by default in driver.
> 
> Change-Id: I2ef2c668fb41fc6c6f448c7c0f1812baf8e7b375
> Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>

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

> ---
>  drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
> b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
> index 8baa890..e24e54c 100644
> --- a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
> +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
> @@ -1535,7 +1535,11 @@ static int vega10_populate_single_gfx_level(struct
> pp_hwmgr *hwmgr,
>  	current_gfxclk_level->FbMult =
>  			cpu_to_le32(dividers.ulPll_fb_mult);
>  	/* Spread FB Multiplier bit: bit 0:8 int, bit 31:16 frac */
> -	current_gfxclk_level->SsOn = dividers.ucPll_ss_enable;
> +	if (phm_cap_enabled(hwmgr->platform_descriptor.platformCaps,
> +
> 	PHM_PlatformCaps_EngineSpreadSpectrumSupport))
> +		current_gfxclk_level->SsOn = dividers.ucPll_ss_enable;
> +	else
> +		current_gfxclk_level->SsOn = 0;
>  	current_gfxclk_level->SsFbMult =
>  			cpu_to_le32(dividers.ulPll_ss_fbsmult);
>  	current_gfxclk_level->SsSlewFrac =
> --
> 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-05-04  3:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-05-04  3:33 [PATCH] drm/amd/powerplay: disable engine spread spectrum feature on Vega10 Rex Zhu
     [not found] ` <1493868804-794-1-git-send-email-Rex.Zhu-5C7GfCeVMHo@public.gmane.org>
2017-05-04  3:48   ` Wang, Ken
2017-05-04  3:52   ` Deucher, Alexander

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.