drm/radeon/dpm: add a late enable callback
Certain features need to be enabled after ring tests (e.g., powergating, etc.). Add a function pointer to split out late enable features. Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
01ac8794a7
commit
914a89872b
2 changed files with 15 additions and 0 deletions
|
@ -1288,6 +1288,18 @@ int radeon_pm_init(struct radeon_device *rdev)
|
|||
return radeon_pm_init_old(rdev);
|
||||
}
|
||||
|
||||
int radeon_pm_late_init(struct radeon_device *rdev)
|
||||
{
|
||||
int ret = 0;
|
||||
|
||||
if (rdev->pm.pm_method == PM_METHOD_DPM) {
|
||||
mutex_lock(&rdev->pm.mutex);
|
||||
ret = radeon_dpm_late_enable(rdev);
|
||||
mutex_unlock(&rdev->pm.mutex);
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
static void radeon_pm_fini_old(struct radeon_device *rdev)
|
||||
{
|
||||
if (rdev->pm.num_power_states > 1) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue