Skip to contentSkip to conversation

drm/amd/powerplay: added vega20 overdrive support V2

PATCH New Evan Quan 1 participant 1 message Aug 30, 2018

Subsystems (2)
lore
Share & tools
lore

Evan Quan

author
#0 lore raw

PATCH 1/1 drm/amd/powerplay: added vega20 overdrive support V2

Added vega20 overdrive support based on existing OD sysfs APIs. However, the OD logics are simplified on vega20. So, the behavior will be a little different and works only on some limited levels.

V2: fix typo
fix commit description
revise error logs
add support for clock OD

Change-Id I403cb38a95863db664cf06d030ac42a19bff6b33
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c        |  30 ++
 .../drm/amd/powerplay/hwmgr/vega20_hwmgr.c    | 281 +++++++++++++++++-
 2 files changed, 310 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_pm.c +30 -0
index e2577518b9c6..30717b1cf38e 100644
@@ -474,6 +474,8 @@ static ssize_t amdgpu_set_pp_table(struct device *dev,
  * in each power level within a power state.  The pp_od_clk_voltage is used for
  * this.
  *
+ * < For Vega10 and previous ASICs >
+ *
  * Reading the file will display:
  *
  * - a list of engine clock levels and voltages labeled OD_SCLK
@@ -491,6 +493,34 @@ static ssize_t amdgpu_set_pp_table(struct device *dev,
  * "c" (commit) to the file to commit your changes.  If you want to reset to the
  * default power levels, write "r" (reset) to the file to reset them.
  *
+ *
+ * < For Vega20 >
+ *
+ * Reading the file will display:
+ *
+ * - engine clock and voltage(offset) labeled OD_SCLK for minimum level,
+ *   middle level and maximum level
+ *
+ * - memory clock and voltage(offset) labeled OD_MCLK for maximum level
+ *   The voltage tuning for memory is not supported temporarily.
+ *
+ * - a list of valid ranges for sclk, mclk, and voltage offset labeled
+ *   OD_RANGE
+ *
+ * To manually adjust these settings:
+ *
+ * - First select manual using power_dpm_force_performance_level
+ *
+ * - Enter a new value for each level by writing a string that contains
+ *   "s/m level clock voltage(offset)" to the file.  E.g., "s 0 500 20"
+ *   will update level 0 sclk to be 500 MHz with voltage increased by 20mV
+ *
+ * - When you have edited all of the states as needed, write "c" (commit)
+ *   to the file to commit your changes
+ *
+ * - If you want to reset to the default power levels, write "r" (reset)
+ *   to the file to reset them
+ *
  */
 
 static ssize_t amdgpu_set_pp_od_clk_voltage(struct device *dev,
drivers/gpu/drm/amd/powerplay/hwmgr/vega20_hwmgr.c +280 -1

303 lines not on this page · raw message

Signature · 6 lines
2.18.0

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx