Skip to content

Commit 5c16f36

Browse files
Kenneth Fengalexdeucher
authored andcommitted
drm/amd/powerplay: Set higher SCLK&MCLK frequency than dpm7 in OD (v2)
Fix the issue that SCLK&MCLK can't be set higher than dpm7 when OD is enabled in SMU7. v2: fix warning (Alex) Signed-off-by: Kenneth Feng <kenneth.feng@amd.com> Acked-by: Rex Zhu<rezhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
1 parent 333c8d3 commit 5c16f36

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3755,14 +3755,17 @@ static int smu7_trim_dpm_states(struct pp_hwmgr *hwmgr,
37553755
static int smu7_generate_dpm_level_enable_mask(
37563756
struct pp_hwmgr *hwmgr, const void *input)
37573757
{
3758-
int result;
3758+
int result = 0;
37593759
const struct phm_set_power_state_input *states =
37603760
(const struct phm_set_power_state_input *)input;
37613761
struct smu7_hwmgr *data = (struct smu7_hwmgr *)(hwmgr->backend);
37623762
const struct smu7_power_state *smu7_ps =
37633763
cast_const_phw_smu7_power_state(states->pnew_state);
37643764

3765-
result = smu7_trim_dpm_states(hwmgr, smu7_ps);
3765+
/*skip the trim if od is enabled*/
3766+
if (!hwmgr->od_enabled)
3767+
result = smu7_trim_dpm_states(hwmgr, smu7_ps);
3768+
37663769
if (result)
37673770
return result;
37683771

0 commit comments

Comments
 (0)