diff options
author | Rex Zhu <Rex.Zhu@amd.com> | 2015-11-04 06:07:34 +0300 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2015-12-22 00:42:28 +0300 |
commit | 09b4c872fe16d5e396de8636f5810078014dbd3f (patch) | |
tree | 14d907037c81721b8d8352c85cb1290d572aa922 /drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c | |
parent | e61710c59dd205b48413762b2aedd46e86df3c45 (diff) | |
download | linux-09b4c872fe16d5e396de8636f5810078014dbd3f.tar.xz |
drm/amd/powerplay: add and export hwmgr interface to eventmgr to check hw states.
Interface between hwmgr and eventmgr.
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c')
-rw-r--r-- | drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c b/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c index 9d910f3284d0..f2d603cff47d 100644 --- a/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c @@ -223,3 +223,24 @@ int phm_start_thermal_controller(struct pp_hwmgr *hwmgr, struct PP_TemperatureRa return phm_dispatch_table(hwmgr, &(hwmgr->start_thermal_controller), temperature_range, NULL); } + + +bool phm_check_smc_update_required_for_display_configuration(struct pp_hwmgr *hwmgr) +{ + if (hwmgr == NULL || hwmgr->hwmgr_func->check_smc_update_required_for_display_configuration == NULL) + return -EINVAL; + + return hwmgr->hwmgr_func->check_smc_update_required_for_display_configuration(hwmgr); +} + + +int phm_check_states_equal(struct pp_hwmgr *hwmgr, + const struct pp_hw_power_state *pstate1, + const struct pp_hw_power_state *pstate2, + bool *equal) +{ + if (hwmgr == NULL || hwmgr->hwmgr_func->check_states_equal == NULL) + return -EINVAL; + + return hwmgr->hwmgr_func->check_states_equal(hwmgr, pstate1, pstate2, equal); +} |