diff options
author | Evan Quan | 2019-05-13 09:32:21 +0200 |
---|---|---|
committer | Alex Deucher | 2019-05-24 19:20:59 +0200 |
commit | fe75a323713e9ed254c4e3d27b391b2416cee237 (patch) | |
tree | b75a32210470b083b33d02cb4f3d9369d3a5605c /drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h | |
parent | drm/amd/powerplay: drop redundant smu call (diff) | |
download | kernel-qcow2-linux-fe75a323713e9ed254c4e3d27b391b2416cee237.tar.gz kernel-qcow2-linux-fe75a323713e9ed254c4e3d27b391b2416cee237.tar.xz kernel-qcow2-linux-fe75a323713e9ed254c4e3d27b391b2416cee237.zip |
drm/amd/powerplay: support ppfeatures sysfs interface on sw smu routine
Support ppfeatures sysfs interface on Vega20 sw smu routine.
Signed-off-by: Evan Quan <evan.quan@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Reviewed-by: Huang Rui <ray.huang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h')
-rw-r--r-- | drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h b/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h index 89052414e9f1..3a9c253759dc 100644 --- a/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h +++ b/drivers/gpu/drm/amd/powerplay/inc/amdgpu_smu.h @@ -458,6 +458,8 @@ struct pptable_funcs { uint32_t *mclk_mask, uint32_t *soc_mask); int (*set_cpu_power_state)(struct smu_context *smu); + int (*set_ppfeature_status)(struct smu_context *smu, uint64_t ppfeatures); + int (*get_ppfeature_status)(struct smu_context *smu, char *buf); }; struct smu_funcs @@ -727,7 +729,10 @@ struct smu_funcs ((smu)->funcs->get_mclk ? (smu)->funcs->get_mclk((smu), (low)) : 0) #define smu_set_xgmi_pstate(smu, pstate) \ ((smu)->funcs->set_xgmi_pstate ? (smu)->funcs->set_xgmi_pstate((smu), (pstate)) : 0) - +#define smu_set_ppfeature_status(smu, ppfeatures) \ + ((smu)->ppt_funcs->set_ppfeature_status ? (smu)->ppt_funcs->set_ppfeature_status((smu), (ppfeatures)) : -EINVAL) +#define smu_get_ppfeature_status(smu, buf) \ + ((smu)->ppt_funcs->get_ppfeature_status ? (smu)->ppt_funcs->get_ppfeature_status((smu), (buf)) : -EINVAL) extern int smu_get_atom_data_table(struct smu_context *smu, uint32_t table, uint16_t *size, uint8_t *frev, uint8_t *crev, |