diff options
author | Rex Zhu <Rex.Zhu@amd.com> | 2016-03-29 09:20:37 +0300 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2016-04-01 17:08:27 +0300 |
commit | 4c90080b19aad59c3a4a91a0a2d68fdee0643c37 (patch) | |
tree | 8802832d09a4e697ed2a8566b4b8c9b0b6ebc872 /drivers/gpu/drm/amd/amdgpu | |
parent | f9e9c08e20d71cabef7d5c2a7eb75e1d953dad16 (diff) | |
download | linux-4c90080b19aad59c3a4a91a0a2d68fdee0643c37.tar.xz |
drm/amdgpu: add an cgs interface to notify amdgpu the dpm state.
Signed-off-by: Rex Zhu <Rex.Zhu@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c index 75cb5b9b88f8..6043dc7c3a94 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cgs.c @@ -850,6 +850,16 @@ static int amdgpu_cgs_get_active_displays_info(void *cgs_device, return 0; } + +static int amdgpu_cgs_notify_dpm_enabled(void *cgs_device, bool enabled) +{ + CGS_FUNC_ADEV; + + adev->pm.dpm_enabled = enabled; + + return 0; +} + /** \brief evaluate acpi namespace object, handle or pathname must be valid * \param cgs_device * \param info input/output arguments for the control method @@ -1100,6 +1110,7 @@ static const struct cgs_ops amdgpu_cgs_ops = { amdgpu_cgs_set_powergating_state, amdgpu_cgs_set_clockgating_state, amdgpu_cgs_get_active_displays_info, + amdgpu_cgs_notify_dpm_enabled, amdgpu_cgs_call_acpi_method, amdgpu_cgs_query_system_info, }; |