summaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
diff options
context:
space:
mode:
authorEric Yang <eric.yang2@amd.com>2015-12-01 21:23:07 +0300
committerAlex Deucher <alexander.deucher@amd.com>2015-12-22 00:42:54 +0300
commit14f634110fa68120ec66e24f1e423e3cc2109c9f (patch)
tree87c3e035d36fc8cd84c8971d385aa2843460b8ff /drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
parent1c9a90820beb63f75ac7dabf75533f425aadc3fa (diff)
downloadlinux-14f634110fa68120ec66e24f1e423e3cc2109c9f.tar.xz
amd/powerplay: Add structures required to report configuration change
Add required structures for amd_powerplay_display_configuration_change Signed-off-by: Eric Yang <eric.yang2@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c')
-rw-r--r--drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c b/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
index 881feb87fc8b..df8937b9a9ac 100644
--- a/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
+++ b/drivers/gpu/drm/amd/powerplay/hwmgr/hardwaremanager.c
@@ -249,16 +249,21 @@ int phm_check_states_equal(struct pp_hwmgr *hwmgr,
int phm_store_dal_configuration_data(struct pp_hwmgr *hwmgr,
const struct amd_pp_display_configuration *display_config)
{
- if (hwmgr == NULL || hwmgr->hwmgr_func->store_cc6_data == NULL)
+
+ if (hwmgr == NULL)
return -EINVAL;
+ hwmgr->display_config = *display_config;
/* to do pass other display configuration in furture */
- return hwmgr->hwmgr_func->store_cc6_data(hwmgr,
- display_config->cpu_pstate_separation_time,
- display_config->cpu_cc6_disable,
- display_config->cpu_pstate_disable,
- display_config->nb_pstate_switch_disable);
+ if (hwmgr->hwmgr_func->store_cc6_data)
+ hwmgr->hwmgr_func->store_cc6_data(hwmgr,
+ display_config->cpu_pstate_separation_time,
+ display_config->cpu_cc6_disable,
+ display_config->cpu_pstate_disable,
+ display_config->nb_pstate_switch_disable);
+
+ return 0;
}
int phm_get_dal_power_level(struct pp_hwmgr *hwmgr,