AMD-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Timur Kristóf" <timur.kristof@gmail.com>
To: amd-gfx@lists.freedesktop.org, alexander.deucher@amd.com,
	Alex Hung <alex.hung@amd.com>,
	Harry Wentland <Harry.Wentland@amd.com>,
	Roman Li <Roman.Li@amd.com>, Leo Li <sunpeng.li@amd.com>,
	David Airlie <airlied@gmail.com>,
	Mario Limonciello <mario.limonciello@amd.com>,
	Ivan Lipski <ivan.lipski@amd.com>, Melissa Wen <mwen@igalia.com>
Subject: Re: [PATCH 03/14] drm/amd/display: Remove min/max clock levels from clk_mgr
Date: Fri, 24 Apr 2026 18:28:50 +0200	[thread overview]
Message-ID: <3592022.LZWGnKmheA@timur-hyperion> (raw)
In-Reply-To: <5132be76-3565-4b4d-8703-8fa49e652ea0@igalia.com>

On Friday, April 24, 2026 4:21:54 PM Central European Summer Time Melissa Wen 
wrote:
> On 23/04/2026 16:15, Timur Kristóf wrote:
> > These fields are not used by anything anymore.
> > 
> > Signed-off-by: Timur Kristóf<timur.kristof@gmail.com>
> > ---
> > 
> >   .../amd/display/dc/clk_mgr/dce100/dce_clk_mgr.c   | 14 --------------
> >   .../display/dc/clk_mgr/dce112/dce112_clk_mgr.c    | 15 ---------------
> >   .../drm/amd/display/dc/inc/hw/clk_mgr_internal.h  |  2 --
> >   3 files changed, 31 deletions(-)
> > 
> > diff --git a/drivers/gpu/drm/amd/display/dc/clk_mgr/dce100/dce_clk_mgr.c
> > b/drivers/gpu/drm/amd/display/dc/clk_mgr/dce100/dce_clk_mgr.c index
> > 988eb6f841f54..2ba341df7fffd 100644
> > --- a/drivers/gpu/drm/amd/display/dc/clk_mgr/dce100/dce_clk_mgr.c
> > +++ b/drivers/gpu/drm/amd/display/dc/clk_mgr/dce100/dce_clk_mgr.c
> > @@ -257,11 +257,6 @@ int dce_set_clock(
> > 
> >   		actual_clock = 
pxl_clk_params.dfs_bypass_display_clock;
> >   	
> >   	}
> > 
> > -	/* from power down, we need mark the clock state as 
ClocksStateNominal
> > -	 * from HWReset, so when resume we will call pplib voltage 
regulator.*/
> > -	if (requested_clk_khz == 0)
> > -		clk_mgr_dce->cur_min_clks_state = 
DM_PP_CLOCKS_STATE_NOMINAL;
> > -
> > 
> >   	if (dmcu && dmcu->funcs->is_dmcu_initialized(dmcu))
> >   	
> >   		dmcu->funcs->set_psr_wait_loop(dmcu, actual_clock / 
1000 / 7);
> > 
> > @@ -425,7 +420,6 @@ void dce_clk_mgr_construct(
> > 
> >   		struct clk_mgr_internal *clk_mgr)
> >   
> >   {
> >   
> >   	struct clk_mgr *base = &clk_mgr->base;
> > 
> > -	struct dm_pp_static_clock_info static_clk_info = {0};
> > 
> >   	if (ctx->dce_version <= DCE_VERSION_6_4)
> >   	
> >   		memcpy(clk_mgr->max_clks_by_state,
> > 
> > @@ -451,14 +445,6 @@ void dce_clk_mgr_construct(
> > 
> >   	clk_mgr->dprefclk_ss_divider = 1000;
> >   	clk_mgr->ss_on_dprefclk = false;
> > 
> > -	if (ctx->dce_version >= DCE_VERSION_8_0) {
> > -		if (dm_pp_get_static_clocks(ctx, &static_clk_info))
> 
> and `dm_pp_get_static_clocks` becomes unused, right?

Looks like nothing else is using dm_pp_get_static_clocks() so that can be 
deleted as well. I can do that in a follow-up series if that's OK.

> 
> > -			clk_mgr->max_clks_state = 
static_clk_info.max_clocks_state;
> > -		else
> > -			clk_mgr->max_clks_state = 
DM_PP_CLOCKS_STATE_NOMINAL;
> > -		clk_mgr->cur_min_clks_state = 
DM_PP_CLOCKS_STATE_INVALID;
> > -	}
> > -
> > 
> >   	base->clks.max_supported_dispclk_khz =
> >   	
> >   		clk_mgr-
>max_clks_by_state[DM_PP_CLOCKS_STATE_PERFORMANCE].display_clk
> >   		_khz;
> > 
> > diff --git
> > a/drivers/gpu/drm/amd/display/dc/clk_mgr/dce112/dce112_clk_mgr.c
> > b/drivers/gpu/drm/amd/display/dc/clk_mgr/dce112/dce112_clk_mgr.c index
> > 48393c69735b6..0f3f8df4df96a 100644
> > --- a/drivers/gpu/drm/amd/display/dc/clk_mgr/dce112/dce112_clk_mgr.c
> > +++ b/drivers/gpu/drm/amd/display/dc/clk_mgr/dce112/dce112_clk_mgr.c
> > @@ -89,13 +89,6 @@ int dce112_set_clock(struct clk_mgr *clk_mgr_base, int
> > requested_clk_khz)> 
> >   	bp->funcs->set_dce_clock(bp, &dce_clk_params);
> >   	actual_clock = dce_clk_params.target_clock_frequency;
> > 
> > -	/*
> > -	 * from power down, we need mark the clock state as 
ClocksStateNominal
> > -	 * from HWReset, so when resume we will call pplib voltage 
regulator.
> > -	 */
> > -	if (requested_clk_khz == 0)
> > -		clk_mgr_dce->cur_min_clks_state = 
DM_PP_CLOCKS_STATE_NOMINAL;
> > -
> > 
> >   	/*Program DP ref Clock*/
> >   	/*VBIOS will determine DPREFCLK frequency, so we don't set it*/
> >   	dce_clk_params.target_clock_frequency = 0;
> > 
> > @@ -143,14 +136,6 @@ int dce112_set_dispclk(struct clk_mgr_internal
> > *clk_mgr, int requested_clk_khz)> 
> >   	bp->funcs->set_dce_clock(bp, &dce_clk_params);
> >   	actual_clock = dce_clk_params.target_clock_frequency;
> > 
> > -	/*
> > -	 * from power down, we need mark the clock state as 
ClocksStateNominal
> > -	 * from HWReset, so when resume we will call pplib voltage 
regulator.
> > -	 */
> > -	if (requested_clk_khz == 0)
> > -		clk_mgr->cur_min_clks_state = 
DM_PP_CLOCKS_STATE_NOMINAL;
> > -
> > -
> > 
> >   	if (dmcu && dmcu->funcs->is_dmcu_initialized(dmcu)) {
> >   	
> >   		if (clk_mgr->dfs_bypass_disp_clk != actual_clock)
> >   		
> >   			dmcu->funcs->set_psr_wait_loop(dmcu,
> > 
> > diff --git a/drivers/gpu/drm/amd/display/dc/inc/hw/clk_mgr_internal.h
> > b/drivers/gpu/drm/amd/display/dc/inc/hw/clk_mgr_internal.h index
> > c69ccfcebeb5a..e01bf6bd7f3f4 100644
> > --- a/drivers/gpu/drm/amd/display/dc/inc/hw/clk_mgr_internal.h
> > +++ b/drivers/gpu/drm/amd/display/dc/inc/hw/clk_mgr_internal.h
> > @@ -477,8 +477,6 @@ struct clk_mgr_internal {
> > 
> >   	 */
> >   	
> >   	int dprefclk_ss_divider;
> > 
> > -	enum dm_pp_clocks_state max_clks_state;
> > -	enum dm_pp_clocks_state cur_min_clks_state;
> > 
> >   	bool periodic_retraining_disabled;
> >   	
> >   	unsigned int cur_phyclk_req_table[MAX_LINKS];





  reply	other threads:[~2026-04-24 16:28 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-23 19:15 [PATCH 00/14] drm/amd: Delete defunct DAL power level code Timur Kristóf
2026-04-23 19:15 ` [PATCH 01/14] drm/amd/display: Delete unimplemented dm_pp_apply_power_level_change_request() Timur Kristóf
2026-04-24 14:19   ` Melissa Wen
2026-04-24 16:27     ` Timur Kristóf
2026-04-29 20:02   ` Melissa Wen
2026-04-23 19:15 ` [PATCH 02/14] drm/amd/display: Delete dce_get_required_clocks_state() Timur Kristóf
2026-04-29 20:03   ` Melissa Wen
2026-04-23 19:15 ` [PATCH 03/14] drm/amd/display: Remove min/max clock levels from clk_mgr Timur Kristóf
2026-04-24 14:21   ` Melissa Wen
2026-04-24 16:28     ` Timur Kristóf [this message]
2026-04-29 20:05       ` Melissa Wen
2026-04-23 19:15 ` [PATCH 04/14] drm/amd/display: Delete max_clocks_state from dm_pp_static_clock_info Timur Kristóf
2026-04-29 20:06   ` Melissa Wen
2026-04-23 19:15 ` [PATCH 05/14] drm/amd/display: Set max supported display clock without max_clks_by_state Timur Kristóf
2026-04-29 20:24   ` Melissa Wen
2026-04-30 12:28     ` Timur Kristóf
2026-04-30 18:06       ` Melissa Wen
2026-04-23 19:15 ` [PATCH 06/14] drm/amd/display: Delete max_clks_by_state from DCE clock manager Timur Kristóf
2026-04-29 20:29   ` Melissa Wen
2026-04-23 19:15 ` [PATCH 07/14] drm/amd/display: Delete disp_clk_voltage from integrated info Timur Kristóf
2026-04-29 20:35   ` Melissa Wen
2026-04-30 12:30     ` Timur Kristóf
2026-04-23 19:15 ` [PATCH 08/14] drm/amd/display: Delete dm_pp_clocks_state Timur Kristóf
2026-04-29 20:37   ` Melissa Wen
2026-04-30 12:31     ` Timur Kristóf
2026-04-23 19:15 ` [PATCH 09/14] drm/amd/pm: Delete unused get_display_power_level() function Timur Kristóf
2026-04-30 17:56   ` Melissa Wen
2026-04-23 19:15 ` [PATCH 10/14] drm/amd/pm: Delete dummy get_dal_power_level implementations Timur Kristóf
2026-04-30 18:42   ` Melissa Wen
2026-04-23 19:15 ` [PATCH 11/14] drm/amd/pm: Delete non-functional SMU8 get_dal_power_level implementation Timur Kristóf
2026-04-30 18:53   ` Melissa Wen
2026-04-23 19:15 ` [PATCH 12/14] drm/amd/pm: Delete vddc_dep_on_dal_pwrl Timur Kristóf
2026-04-30 19:03   ` Melissa Wen
2026-04-23 19:15 ` [PATCH 13/14] drm/amd/pm: Delete get_dal_power_level Timur Kristóf
2026-04-30 19:03   ` Melissa Wen
2026-04-23 19:15 ` [PATCH 14/14] drm/amd/pm: Delete PP_DAL_POWERLEVEL Timur Kristóf
2026-04-30 19:04   ` Melissa Wen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=3592022.LZWGnKmheA@timur-hyperion \
    --to=timur.kristof@gmail.com \
    --cc=Harry.Wentland@amd.com \
    --cc=Roman.Li@amd.com \
    --cc=airlied@gmail.com \
    --cc=alex.hung@amd.com \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=ivan.lipski@amd.com \
    --cc=mario.limonciello@amd.com \
    --cc=mwen@igalia.com \
    --cc=sunpeng.li@amd.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox