Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 89c9bc56 authored by Alex Deucher's avatar Alex Deucher
Browse files

drm/radeon/dpm: remove broken dyn state remnants



Now that the proper fix has been implemented I can
remove the last remnants of the initial implementation.

Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent fee3d744
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -1302,7 +1302,6 @@ struct radeon_dpm {
	struct radeon_ps        *boot_ps;
	/* default uvd power state */
	struct radeon_ps        *uvd_ps;
	struct radeon_ps        hw_ps;
	enum radeon_pm_state_type state;
	enum radeon_pm_state_type user_state;
	u32                     platform_caps;
+5 −19
Original line number Diff line number Diff line
@@ -684,17 +684,6 @@ static struct radeon_ps *radeon_dpm_pick_power_state(struct radeon_device *rdev,
	return NULL;
}

static void radeon_dpm_update_requested_ps(struct radeon_device *rdev,
					   struct radeon_ps *ps)
{
	/* copy the ps to the hw ps and point the requested ps
	 * at the hw state in case the driver wants to modify
	 * the state dynamically.
	 */
	rdev->pm.dpm.hw_ps = *ps;
	rdev->pm.dpm.requested_ps = &rdev->pm.dpm.hw_ps;
}

static void radeon_dpm_change_power_state_locked(struct radeon_device *rdev)
{
	int i;
@@ -716,7 +705,7 @@ static void radeon_dpm_change_power_state_locked(struct radeon_device *rdev)

	ps = radeon_dpm_pick_power_state(rdev, dpm_state);
	if (ps)
		radeon_dpm_update_requested_ps(rdev, ps);
		rdev->pm.dpm.requested_ps = ps;
	else
		return;

@@ -767,11 +756,9 @@ static void radeon_dpm_change_power_state_locked(struct radeon_device *rdev)
	down_write(&rdev->pm.mclk_lock);
	mutex_lock(&rdev->ring_lock);

	if (rdev->asic->dpm.pre_set_power_state) {
	ret = radeon_dpm_pre_set_power_state(rdev);
	if (ret)
		goto done;
	}

	/* update display watermarks based on new power state */
	radeon_bandwidth_update(rdev);
@@ -794,7 +781,6 @@ static void radeon_dpm_change_power_state_locked(struct radeon_device *rdev)
	/* update current power state */
	rdev->pm.dpm.current_ps = rdev->pm.dpm.requested_ps;

	if (rdev->asic->dpm.post_set_power_state)
	radeon_dpm_post_set_power_state(rdev);

done: