drm/amdgpu: add an interface of amdgpu_dpm_set_mmhub_powergating_by_smu
authorEric Huang <JinHuiEric.Huang@amd.com>
Tue, 6 Feb 2018 21:19:24 +0000 (16:19 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 19 Feb 2018 19:19:39 +0000 (14:19 -0500)
Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_dpm.h
drivers/gpu/drm/amd/include/kgd_pp_interface.h

index c489c69fb5ed52fdc24d46df7a17f6a022a3f175..bd745a4fae0ce7c8edc5e0292dd27b44cdab8687 100644 (file)
@@ -375,6 +375,10 @@ enum amdgpu_pcie_gen {
                ((adev)->powerplay.pp_funcs->odn_edit_dpm_table(\
                        (adev)->powerplay.pp_handle, type, parameter, size))
 
+#define amdgpu_dpm_set_mmhub_powergating_by_smu(adev) \
+               ((adev)->powerplay.pp_funcs->set_mmhub_powergating_by_smu( \
+               (adev)->powerplay.pp_handle))
+
 struct amdgpu_dpm {
        struct amdgpu_ps        *ps;
        /* number of valid power states */
index 1fc995b2b26fea845e6f2cb1f844ce3028eeee5e..4f69fe8ca3715977ba0d1a1ad4ed2bd1af9fcc42 100644 (file)
@@ -310,6 +310,7 @@ struct amd_pm_funcs {
        int (*get_power_profile_mode)(void *handle, char *buf);
        int (*set_power_profile_mode)(void *handle, long *input, uint32_t size);
        int (*odn_edit_dpm_table)(void *handle, uint32_t type, long *input, uint32_t size);
+       int (*set_mmhub_powergating_by_smu)(void *handle);
 };
 
 #endif