projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ce09d8e
)
drm/amd/powerplay: add avfs check for old asics on Vi.
author
Rex Zhu
<
[email protected]
>
Mon, 3 Jul 2017 09:50:45 +0000
(17:50 +0800)
committer
Alex Deucher
<
[email protected]
>
Fri, 14 Jul 2017 15:06:16 +0000
(11:06 -0400)
Signed-off-by: Rex Zhu <
[email protected]
>
Reviewed-by: Alex Deucher <
[email protected]
>
Signed-off-by: Alex Deucher <
[email protected]
>
drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
b/drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
index 1f01020ce3a92a34baa5b3d8257f974008143179..f01cda93f17864a683b39d6c9e9aaa02414bc69c 100644
(file)
--- a/
drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
+++ b/
drivers/gpu/drm/amd/powerplay/hwmgr/smu7_hwmgr.c
@@
-4630,6
+4630,15
@@
static int smu7_set_power_profile_state(struct pp_hwmgr *hwmgr,
static int smu7_avfs_control(struct pp_hwmgr *hwmgr, bool enable)
{
+ struct pp_smumgr *smumgr = (struct pp_smumgr *)(hwmgr->smumgr);
+ struct smu7_smumgr *smu_data = (struct smu7_smumgr *)(smumgr->backend);
+
+ if (smu_data == NULL)
+ return -EINVAL;
+
+ if (smu_data->avfs.avfs_btc_status == AVFS_BTC_NOTSUPPORTED)
+ return 0;
+
if (enable) {
if (!PHM_READ_VFPF_INDIRECT_FIELD(hwmgr->device,
CGS_IND_REG__SMC, FEATURE_STATUS, AVS_ON))