[PATCH 2/4] drm/amd/powerplay: Remove obsolete code of reduced refresh rate featur

Deucher, Alexander Alexander.Deucher at amd.com
Fri Aug 25 15:38:37 UTC 2017


> -----Original Message-----
> From: amd-gfx [mailto:amd-gfx-bounces at lists.freedesktop.org] On Behalf
> Of Rex Zhu
> Sent: Friday, August 25, 2017 5:27 AM
> To: amd-gfx at lists.freedesktop.org
> Cc: Zhu, Rex
> Subject: [PATCH 2/4] drm/amd/powerplay: Remove obsolete code of
> reduced refresh rate featur

Typo in patch title:  featur -> feature

With that fixed:
Reviewed-by: Alex Deucher <alexander.deucher at amd.com>

> 
> this feature was not supported on linux and obsolete.
> 
> Change-Id: I7434e9370e4a29489bff7feb1421e028710fbe14
> Signed-off-by: Rex Zhu <Rex.Zhu at amd.com>
> ---
>  drivers/gpu/drm/amd/include/pptable.h                 |  6 ------
>  drivers/gpu/drm/amd/powerplay/hwmgr/processpptables.c | 18 -------------
> -----
>  drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c      |  1 -
>  drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c    |  1 -
>  drivers/gpu/drm/amd/powerplay/inc/power_state.h       |  4 ----
>  5 files changed, 30 deletions(-)
> 
> diff --git a/drivers/gpu/drm/amd/include/pptable.h
> b/drivers/gpu/drm/amd/include/pptable.h
> index 0b6a057..1dda72a 100644
> --- a/drivers/gpu/drm/amd/include/pptable.h
> +++ b/drivers/gpu/drm/amd/include/pptable.h
> @@ -285,12 +285,6 @@
>  #define ATOM_PPLIB_PCIE_LINK_WIDTH_MASK            0x000000F8
>  #define ATOM_PPLIB_PCIE_LINK_WIDTH_SHIFT           3
> 
> -// lookup into reduced refresh-rate table
> -#define ATOM_PPLIB_LIMITED_REFRESHRATE_VALUE_MASK  0x00000F00
> -#define ATOM_PPLIB_LIMITED_REFRESHRATE_VALUE_SHIFT 8
> -
> -#define ATOM_PPLIB_LIMITED_REFRESHRATE_UNLIMITED    0
> -#define ATOM_PPLIB_LIMITED_REFRESHRATE_50HZ         1
>  // 2-15 TBD as needed.
> 
>  #define ATOM_PPLIB_SOFTWARE_DISABLE_LOADBALANCING
> 0x00001000
> diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/processpptables.c
> b/drivers/gpu/drm/amd/powerplay/hwmgr/processpptables.c
> index 707809b..f974832 100644
> --- a/drivers/gpu/drm/amd/powerplay/hwmgr/processpptables.c
> +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/processpptables.c
> @@ -680,7 +680,6 @@ static int init_non_clock_fields(struct pp_hwmgr
> *hwmgr,
>  							    uint8_t version,
>  			 const ATOM_PPLIB_NONCLOCK_INFO
> *pnon_clock_info)
>  {
> -	unsigned long rrr_index;
>  	unsigned long tmp;
> 
>  	ps->classification.ui_label = (le16_to_cpu(pnon_clock_info-
> >usClassification) &
> @@ -709,23 +708,6 @@ static int init_non_clock_fields(struct pp_hwmgr
> *hwmgr,
> 
>  	ps->display.disableFrameModulation = false;
> 
> -	rrr_index = (le32_to_cpu(pnon_clock_info->ulCapsAndSettings) &
> -
> 	ATOM_PPLIB_LIMITED_REFRESHRATE_VALUE_MASK) >>
> -			ATOM_PPLIB_LIMITED_REFRESHRATE_VALUE_SHIFT;
> -
> -	if (rrr_index != ATOM_PPLIB_LIMITED_REFRESHRATE_UNLIMITED) {
> -		static const uint8_t
> look_up[(ATOM_PPLIB_LIMITED_REFRESHRATE_VALUE_MASK >>
> ATOM_PPLIB_LIMITED_REFRESHRATE_VALUE_SHIFT) + 1] = \
> -								{ 0, 50, 0 };
> -
> -		ps->display.refreshrateSource =
> PP_RefreshrateSource_Explicit;
> -		ps->display.explicitRefreshrate = look_up[rrr_index];
> -		ps->display.limitRefreshrate = true;
> -
> -		if (ps->display.explicitRefreshrate == 0)
> -			ps->display.limitRefreshrate = false;
> -	} else
> -		ps->display.limitRefreshrate = false;
> -
>  	tmp = le32_to_cpu(pnon_clock_info->ulCapsAndSettings) &
>  		ATOM_PPLIB_ENABLE_VARIBRIGHT;
> 
> diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
> b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
> index 736f193..27bd1a0 100644
> --- a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
> +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
> @@ -2990,7 +2990,6 @@ static int
> smu7_get_pp_table_entry_callback_func_v1(struct pp_hwmgr *hwmgr,
>  	power_state->pcie.lanes = 0;
> 
>  	power_state->display.disableFrameModulation = false;
> -	power_state->display.limitRefreshrate = false;
>  	power_state->display.enableVariBright =
>  			(0 != (le32_to_cpu(state_entry->ulCapsAndSettings)
> &
> 
> 	ATOM_Tonga_ENABLE_VARIBRIGHT));
> diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
> b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
> index 29e44c3..f20758f 100644
> --- a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
> +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c
> @@ -3021,7 +3021,6 @@ static int
> vega10_get_pp_table_entry_callback_func(struct pp_hwmgr *hwmgr,
>  					ATOM_Vega10_DISALLOW_ON_DC)
> != 0);
> 
>  	power_state->display.disableFrameModulation = false;
> -	power_state->display.limitRefreshrate = false;
>  	power_state->display.enableVariBright =
>  			((le32_to_cpu(state_entry->ulCapsAndSettings) &
> 
> 	ATOM_Vega10_ENABLE_VARIBRIGHT) != 0);
> diff --git a/drivers/gpu/drm/amd/powerplay/inc/power_state.h
> b/drivers/gpu/drm/amd/powerplay/inc/power_state.h
> index 827860f..44069f7 100644
> --- a/drivers/gpu/drm/amd/powerplay/inc/power_state.h
> +++ b/drivers/gpu/drm/amd/powerplay/inc/power_state.h
> @@ -98,10 +98,6 @@ enum PP_RefreshrateSource {
> 
>  struct PP_StateDisplayBlock {
>  	bool              disableFrameModulation;
> -	bool              limitRefreshrate;
> -	enum PP_RefreshrateSource refreshrateSource;
> -	int                  explicitRefreshrate;
> -	int                  edidRefreshrateIndex;
>  	bool              enableVariBright;
>  };
> 
> --
> 1.9.1
> 
> _______________________________________________
> amd-gfx mailing list
> amd-gfx at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx


More information about the amd-gfx mailing list