提交 773c3fa3 编写于 作者: A Alex Deucher 提交者: Dave Airlie

drm/radeon/kms/pm: fix power state indexing on igp chips in dynpm mode

Fixes:
https://bugs.freedesktop.org/show_bug.cgi?id=28745Signed-off-by: NAlex Deucher <alexdeucher@gmail.com>
Tested-by: NRafał Miłecki <zajec5@gmail.com>
Signed-off-by: NDave Airlie <airlied@redhat.com>
上级 3f53eb6f
...@@ -130,9 +130,14 @@ void r600_pm_get_dynpm_state(struct radeon_device *rdev) ...@@ -130,9 +130,14 @@ void r600_pm_get_dynpm_state(struct radeon_device *rdev)
break; break;
} }
} }
} else } else {
rdev->pm.requested_power_state_index = if (rdev->pm.current_power_state_index == 0)
rdev->pm.current_power_state_index - 1; rdev->pm.requested_power_state_index =
rdev->pm.num_power_states - 1;
else
rdev->pm.requested_power_state_index =
rdev->pm.current_power_state_index - 1;
}
} }
rdev->pm.requested_clock_mode_index = 0; rdev->pm.requested_clock_mode_index = 0;
/* don't use the power state if crtcs are active and no display flag is set */ /* don't use the power state if crtcs are active and no display flag is set */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册