summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/powerplay
AgeCommit message (Collapse)AuthorFilesLines
2017-09-12drm/amd/powerplay: Tidy up vega10_fan_ctrl_set_default_mode()Tom St Denis1-7/+6
Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: Tidy up vega10_fan_ctrl_set_static_mode()Tom St Denis1-12/+9
Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: Tidy up vega10_fan_ctrl_get_fan_speed_rpm()Tom St Denis1-5/+6
Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: Port vega10_thermal.c over to PP_CAPTom St Denis1-11/+5
Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: Port vega10_powertune.c over to PP_CAPTom St Denis1-25/+22
Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: Port vega10_hwmgr.c over to PP_CAPTom St Denis1-59/+32
Replace and cleanup lengthy phm_cap_enabled() sequences with PP_CAP. Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: Add PP_CAP() macroTom St Denis1-0/+2
To replace common lengthy sequence that would create really long lines all over. Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: Port vega10_didt_set_mask() to new macrosTom St Denis1-40/+20
Start using new CGS bitmask macros. Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: Simplify vega10_acg_disable()Tom St Denis1-6/+4
Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: Simplify ↵Tom St Denis1-52/+23
vega10_patch_voltage_dependency_tables_with_lookup_table() Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: Fix psm_set_user_performance_state()Tom St Denis3-7/+7
We now pass a pointer to a pointer which seems to be what they meant in the first place. The previous version was modifying a pointer passed by value. Fixes bug that was introduced by commit 332798d40c2e91:drm/amd/powerplay: delete eventmgr layer in poweprlay Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reviewed-By: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: set uvd/vce/nb/mclk level as UMD P-state requiredRex Zhu1-3/+9
Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: add UMD P-state in powerplay.Rex Zhu5-132/+66
This feature is for UMD to run benchmark in a power state that is as steady as possible. kmd need to fix the power state as stable as possible. now, kmd support four level: profile_standard,peak,min_sclk,min_mclk move common related code to amd_powerplay.c Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: delete eventmgr related files.Rex Zhu16-2405/+0
Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-12drm/amd/powerplay: delete eventmgr layer in poweprlayRex Zhu10-274/+467
Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-09-01drm/amd/powerplay: fix sclk setting for profile mode for CZ/STAlex Deucher1-46/+1
Need to select dpm0 to avoid clock fluctuations. Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-08-29drm/amd/powerplay/hwmgr: Remove null check before kfreeHimanshu Jha4-105/+53
kfree on NULL pointer is a no-op and therefore checking is redundant. Reviewed-by: Harry Wentland <harry.wentland@amd.com> Reviewed-by: Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Himanshu Jha <himanshujha199640@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-08-29drm/amd: Remove null check before kfreeHimanshu Jha1-4/+2
Kfree on NULL pointer is a no-op and therefore checking is redundant. Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Himanshu Jha <himanshujha199640@gmail.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-08-29drm/amd/powerplay: notify smu once display changed on Rv.Rex Zhu4-20/+43
when User turn off display or screen idle timeout, smu need this message to start S0i2 entry. 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>
2017-08-29drm/amd/powerplay: add dummy pp table for raven. (v2)Rex Zhu1-12/+49
As there is no PPTable in RV, it is difficult to cleanly decouple PPTABLE functionality in existing codes. v2: agd: squash in clean build fix 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>
2017-08-29drm/amd/powerplay: refine pp code for ravenRex Zhu1-119/+16
delete useless code. 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>
2017-08-29drm/amdgpu/powerplay/vega10: fix typo in register base indexAlex Deucher1-1/+1
Probably a copy pasta. No functional difference, both have the same value. Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com> Reported-by: Michael von Khurja <mvonkhurja@techpowerup.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-08-29drm/amd/powerplay: ACG frequency added in PPTableEvan Quan2-5/+12
Signed-off-by: Evan Quan <evan.quan@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-08-29drm/amd/powerplay: unhalt mec after loadingEvan Quan1-1/+2
Signed-off-by: Evan Quan <evan.quan@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-08-15drm/amd/powerplay: fix coding style in hwmgr.cRex Zhu1-7/+7
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>
2017-08-15drm/amd/powerplay: refine dmesg info under powerplay.Rex Zhu2-8/+7
Use pr_debug to prevent spamming unimportant dmesg. 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>
2017-08-15drm/amd/powerplay: fix coccinelle warnings in vega10_hwmgr.cRex Zhu1-1/+1
delete unneeded semicolon. 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>
2017-08-15drm/amd/powerplay: add CZ profile supportAlex Deucher1-2/+80
Support the profiling modes for sclk. v2: delete profileing mode for mclk. Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Tested-and-Reviewed-by Rex Zhu <Rex.Zhu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
2017-08-15drm/amd/powerplay: fix PSI not enabled by kmdRex Zhu2-1/+4
cherry-pick from windows driver. 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>
2017-08-15drm/amd/powerplay: fix set highest mclk level failed on Vega10Rex Zhu1-6/+27
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>
2017-08-15drm/amd/powerplay: fix force dpm level failed on CZRex Zhu1-16/+21
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>
2017-08-15drm/amd/powerplay: add vclk/dclkSoftMin support for ravenJunwei Zhang4-1/+19
Signed-off-by: Junwei Zhang <Jerry.Zhang@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-08-15drm/amd/powerplay: update didt configsEvan Quan1-3/+3
Signed-off-by: Evan Quan <evan.quan@amd.com> Reviewed-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-08-15drm/amd/powerplay: updated vega10 fan controlEvan Quan1-5/+1
Signed-off-by: Evan Quan <evan.quan@amd.com> Reviewed-by: Huang Rui <ray.huang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-08-15drm/amd/powerplay: delete PCC error message in smu7_hwmgr.cRex Zhu1-3/+0
In some asics,Really no need to program PCC HW register. 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>
2017-07-25drm/amd/powerplay: add support for 3DP 4K@120Hz on vega10.Rex Zhu1-8/+80
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>
2017-07-25drm/amd/powerplay: fix AVFS voltage offset for Vega10Eric Huang1-9/+3
Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-07-14drm/amd/powerplay: add profile mode for vega10.Rex Zhu2-25/+109
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>
2017-07-14drm/amd/powerplay: added didt support for vega10Evan Quan7-0/+1381
Signed-off-by: Evan Quan <evan.quan@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-07-14drm/amd/powerplay: add avfs check for old asics on Vi.Rex Zhu1-0/+9
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>
2017-07-14drm/amd/powerplay: move VI common AVFS code to smu7_smumgr.cRex Zhu10-87/+75
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>
2017-07-14drm/amd/powerplay: refine avfs enable code on fiji.Rex Zhu3-107/+28
1. simplify avfs state switch. 2. delete save/restore VFT table functions as not support by fiji. 3. implement thermal_avfs_enable funciton. Signed-off-by: Rex Zhu <Rex.Zhu@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-07-14drm/amd/powerplay: fix avfs state update error on polaris.Rex Zhu1-2/+3
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>
2017-07-14drm/amd/powerplay: enable ACG feature on vega10.Rex Zhu2-4/+80
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>
2017-07-14drm/amd/powerplay: add acg support in pptable for vega10Rex Zhu1-1/+4
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>
2017-07-14drm/amd/powerplay: export ACG related smu message for vega10Rex Zhu2-6/+11
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>
2017-07-14drm/amd/powerplay: add avfs profiling_info_v4_2 support on Vega10.Rex Zhu2-70/+177
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>
2017-07-14drm/amdgpu: add ACG SMU firmware for other vega10 variantsEvan Quan1-1/+2
Signed-off-by: Evan Quan <evan.quan@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-07-14drm/amdgpu: drop SMU_DRIVER_IF_VERSION check for some vega10 variantsEvan Quan1-6/+24
Signed-off-by: Evan Quan <evan.quan@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2017-06-29drm/amd/powerplay: power value format change for Vega10Eric Huang1-2/+7
Power value is an integer on vega10. Signed-off-by: Eric Huang <JinHuiEric.Huang@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>