amdgpu/pm: Implement parallel sysfs_emit solution for vega10
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest2 patches 2 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | amdgpu/pm: Add new hwmgr API function "emit_clock_levels"drivers/ drivers/ | +19 | 0 replies | |
| 2/2 | amdgpu/pm: Implement emit_clk_levels for vega10drivers/ | +147 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH v1 0/2] amdgpu/pm: Implement parallel sysfs_emit solution for vega10
== Description ==
Scnprintf use within the kernel is not recommended, but simple sysfs_emit replacement has not been successful due to the page alignment requirement of the function. This patch set implements a new api "emit_clock_levels" to facilitate passing both the base and offset to the device rather than just the write pointer.
The emit_clock_levels API for amdgpu_dpm has been duplicated to pp_dpm, based on the patch
commit 7f36948c92b2 ("amdgpu/pm: Implement new API function "emit" that accepts buffer base and write offset")
and vega10_emit_clock_levels has been implemented with sysfs_emit based on vega10_print_clock_levels
== Patch Summary ==
linux: ([email protected]:agd5f) origin/amd-staging-drm-next @ 6b6b9c625004
+ e94021f6c08c amdgpu/pm: Add new hwmgr API function "emit_clock_levels"
+ d83131987718 amdgpu/pm: Implement emit_clk_levels for vega10
== System Summary ==
* DESKTOP(AMD FX-8350 + VEGA10(687f/c3), BIOS: F2)
+ ISO(Ubuntu 20.04.4 LTS)
+ Kernel(5.16.0-20220307-fdoagd5f-g6b6b9c625004)
+ Overdrive Enabled(amdgpu.ppfeaturemask |= 0x4000)
== Test ==
AMDGPU_PCI_ADDR=lspci -nn | grep "VGA\|Display" | cut -d " " -f 1 AMDGPU_HWMON=ls -la /sys/class/hwmon | grep $AMDGPU_PCI_ADDR | awk '{print $9}' HWMON_DIR=/sys/class/hwmon/${AMDGPU_HWMON}
lspci -nn | grep "VGA\|Display" > $LOGFILE
printf 'OD enabled = %X\n' "$(( cat /sys/module/amdgpu/parameters/ppfeaturemask & 0x4000 ))" >> $LOGFILE FILES="pp_od_clk_voltagepp_dpm_sclkpp_dpm_mclkpp_dpm_pciepp_dpm_socclkpp_dpm_fclkpp_dpm_dcefclkpp_dpm_vclkpp_dpm_dclk "
for f in $FILES
do
echo === $f === >> $LOGFILE
cat $HWMON_DIR/device/$f >> $LOGFILE
done
cat $LOGFILE
Darren Powell (2):
amdgpu/pm: Add new hwmgr API function "emit_clock_levels" amdgpu/pm: Implement emit_clk_levels for vega10
.../gpu/drm/amd/pm/powerplay/amd_powerplay.c | 17 ++ .../drm/amd/pm/powerplay/hwmgr/vega10_hwmgr.c | 147 ++++++++++++++++++ drivers/gpu/drm/amd/pm/powerplay/inc/hwmgr.h | 2 + 3 files changed, 166 insertions(+)
base-commit: 6b6b9c625004e07e000ca1918cadcb64439eb498
Signature · 1 line
2.35.1