]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
drm/amd/pm: Use pm_display_cfg in legacy DPM (v2)
authorTimur Kristóf <timur.kristof@gmail.com>
Tue, 9 Sep 2025 14:17:51 +0000 (16:17 +0200)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 15 Sep 2025 20:52:46 +0000 (16:52 -0400)
commit9d73b107a61b73e7101d4b728ddac3d2c77db111
tree6c14ba6dd67bb841843cce65f843dbae336da722
parentb515dcb0dc4e85d8254f5459cfb32fce88dacbfb
drm/amd/pm: Use pm_display_cfg in legacy DPM (v2)

This commit is necessary for DC to function well with chips
that use the legacy power management code, ie. SI and KV.
Communicate display information from DC to the legacy PM code.

Currently DC uses pm_display_cfg to communicate power management
requirements from the display code to the DPM code.
However, the legacy (non-DC) code path used different fields
and therefore could not take into account anything from DC.

Change the legacy display code to fill the same pm_display_cfg
struct as DC and use the same in the legacy DPM code.

To ease review and reduce churn, this commit does not yet
delete the now unneeded code, that is done in the next commit.

v2:
Rebase.
Fix single_display in amdgpu_dpm_pick_power_state.

Signed-off-by: Timur Kristóf <timur.kristof@gmail.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/pm/amdgpu_dpm_internal.c
drivers/gpu/drm/amd/pm/inc/amdgpu_dpm_internal.h
drivers/gpu/drm/amd/pm/legacy-dpm/kv_dpm.c
drivers/gpu/drm/amd/pm/legacy-dpm/legacy_dpm.c
drivers/gpu/drm/amd/pm/legacy-dpm/si_dpm.c
drivers/gpu/drm/amd/pm/powerplay/amd_powerplay.c