[PATCH 0/8] amdgpu/pm: Powerplay API for smu

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



=== Description ===
Patches to add the Powerplay API to smu and simplify dpm/pm calling code


=== Patch Summary ===
  linux: (git@xxxxxxxxxxxxxxxxxxxxxx:agd5f/linux.git) origin/amd-staging-drm-next @ 317990c7e076 
   +  linux-d0f58ed28940 0001 amdgpu/pm: Powerplay API for smu , added get_performance_level
   +  linux-967cbf5a4913 0002 amdgpu/pm: Powerplay API for smu , changed 6 dpm reset functions to use API
   +  linux-33609db56fc2 0003 amdgpu/pm: Powerplay API for smu , changed 6 pm hwmon fan functions to use API
   +  linux-b0fc029cae9a 0004 amdgpu/pm: Powerplay API for smu , changed 9 pm power functions to use API
   +  linux-652a3e289f65 0005 amdgpu/pm: Powerplay API for smu , changed 5 dpm powergating & sensor functions to use API
   +  linux-543e989b1fff 0006 amdgpu/pm: Powerplay API for smu , changes to clock and profile mode functions
   +  linux-d41572ad4199 0007 amdgpu/pm: Powerplay API for smu , changed 4 dpm functions to use API
   +  linux-6576162aaf40 0008 amdgpu/pm: Powerplay API for smu , updates to some pm functions

=== Versions ===
 * Version 3 Updates
  0003 Add a wrapper function to set_fan_control_mode for Powerplay API
       Resolved context clashes caused by commits cc8f099288eac, 9485ed36411b7, 66727e187083f
  0004 Removed smu implementation of powerplay get_power_limit, which clashed with commit dfb3bb7fccb37
       Resolved context clashes caused by commits 9485ed36411b7, 766e03739bce7
  0006 Updated to include new clocks vclk, dclk, od_vddgfx_offset, od_cclk added in commits 771fc82ffc710 & f40074fde207e
       Added forward declaration for function smu_force_smuclk_levels to resolve clash with commit 9485ed36411b7
       Resolved context clashes with commit dfb3bb7fccb37 and v3 updates to patches 0003, 0004
  0007 Resolved context clashes with v3 updates to patches 0003
  0008 Resolved context clashes with v3 updates to patches 0003

 * Version 2 Updates
  0001: updated the structure name to swsmu_pm_funcs
  0003: changed error return value of smu_get_fan_control_mode to AMD_FAN_CTRL_NONE
        fixed type in amdgpu_hwmon_get_pwm1_enable() print statement
        fixed indent flagged by checkpatch.pl
  0004: remove check for error during swsmu amdgpu_dpm_get_pp_num_states() call to match previous powerplay behaviour
  0005: add comment to highlight assignment that changes uint32_t value to int
        fix errors flagged by checkpatch.pl
  0006: fix errors flagged by checkpatch
  0007: fix errors and warnings flagged by checkpatch

=== Test System ===
* DESKTOP(AMD FX-8350 + NAVI10(731F/ca), BIOS: F2)
 + ISO(Ubuntu 20.04.2 LTS)
 + Kernel(5.9.0-rc5-custom-01408-g317990c7e076)

=== Tests ===
** 0001
 amdgpu_get_power_dpm_force_performance_level()    <- /sys/class/drm/card0/device/power_dpm_force_performance_level
** 0002
 amdgpu_dpm_set_mp1_state              <- systemctl suspend
 amdgpu_dpm_mode2_reset                <- untested: needs Arctic Islands Hardware (VEGAx, RAVEN)
 amdgpu_dpm_switch_power_profile       <- untested
 amdgpu_dpm_set_xgmi_pstate            <- untested: amdgpu_xgmi_set_pstate():411 pstate switching disabled
 amdgpu_dpm_set_df_cstate              <- untested: needs ras enabled hardware
 amdgpu_dpm_enable_mgpu_fan_boost      <- untested: needs multi-gpu hardware
** 0003
 amdgpu_hwmon_get_pwm1_enable                    <- /sys/class/drm/card0/device/hwmon/hwmon?/pwm1_enable
 amdgpu_hwmon_set_pwm1_enable                    <- /sys/class/drm/card0/device/hwmon/hwmon?/pwm1_enable
 amdgpu_hwmon_set_pwm1                           <- /sys/class/drm/card0/device/hwmon/hwmon?/pwm1
 amdgpu_hwmon_get_pwm1                           <- /sys/class/drm/card0/device/hwmon/hwmon?/pwm1
 amdgpu_hwmon_get_fan1_input                     <- /sys/class/drm/card0/device/hwmon/hwmon?/fan1_input
 amdgpu_hwmon_get_fan1_target                    <- /sys/class/drm/card0/device/hwmon/hwmon?/fan1_target
 amdgpu_hwmon_set_fan1_target                    <- /sys/class/drm/card0/device/hwmon/hwmon?/fan1_target
 amdgpu_hwmon_get_fan1_enable                    <- /sys/class/drm/card0/device/hwmon/hwmon?/fan1_enable
 amdgpu_hwmon_set_fan1_enable                    <- /sys/class/drm/card0/device/hwmon/hwmon?/fan1_enable
** 0004
 amdgpu_get_power_dpm_state                      <- /sys/class/drm/card0/device/power_dpm_state
 amdgpu_set_power_dpm_force_performance_level    <- /sys/class/drm/card0/device/power_dpm_force_performance_level
 amdgpu_get_pp_num_states                        <- /sys/class/drm/card0/device/pp_num_states
 amdgpu_get_pp_cur_state                         <- /sys/class/drm/card0/device/pp_cur_state
 amdgpu_get_pp_table                             <- /sys/class/drm/card0/device/pp_table
 amdgpu_get_pp_features                          <- /sys/class/drm/card0/device/pp_features
 amdgpu_hwmon_show_power_cap_max                 <- /sys/class/drm/card0/device/hwmon/hwmon?/power1_cap_max
 amdgpu_hwmon_show_power_cap                     <- /sys/class/drm/card0/device/hwmon/hwmon?/power1_cap
 amdgpu_hwmon_set_power_cap                      <- /sys/class/drm/card0/device/hwmon/hwmon?/power1_cap
** 0005
 amdgpu_dpm_baco_enter                  <- untested: called from runtime.pm 
 amdgpu_dpm_baco_exit                   <- untested: called from runtime.pm 
 amdgpu_dpm_is_baco_supported           <- untested: needs other Hardware(cik, vi, soc15)
 amdgpu_dpm_baco_reset                  <- untested: needs other Hardware(cik, vi, soc15)
** 0006
 amdgpu_get_pp_dpm_sclk              <- /sys/class/drm/card0/device/pp_dpm_sclk
 amdgpu_set_pp_dpm_sclk              <- /sys/class/drm/card0/device/pp_dpm_sclk
 amdgpu_get_pp_dpm_mclk              <- /sys/class/drm/card0/device/pp_dpm_mclk
 amdgpu_set_pp_dpm_mclk              <- /sys/class/drm/card0/device/pp_dpm_mclk
 amdgpu_get_pp_dpm_socclk            <- /sys/class/drm/card0/device/pp_dpm_socclk
 amdgpu_set_pp_dpm_socclk            <- /sys/class/drm/card0/device/pp_dpm_socclk
 amdgpu_get_pp_dpm_fclk              <- /sys/class/drm/card0/device/pp_dpm_fclk
 amdgpu_set_pp_dpm_fclk              <- /sys/class/drm/card0/device/pp_dpm_fclk
 amdgpu_get_pp_dpm_dcefclk           <- /sys/class/drm/card0/device/pp_dpm_dcefclk
 amdgpu_set_pp_dpm_dcefclk           <- /sys/class/drm/card0/device/pp_dpm_dcefclk
 amdgpu_get_pp_dpm_pcie              <- /sys/class/drm/card0/device/pp_dpm_pcie
 amdgpu_set_pp_dpm_pcie              <- /sys/class/drm/card0/device/pp_dpm_pcie
 amdgpu_get_pp_dpm_vclk              <- /sys/class/drm/card0/device/pp_dpm_vclk
 amdgpu_set_pp_dpm_vclk              <- /sys/class/drm/card0/device/pp_dpm_vclk
 amdgpu_get_pp_dpm_dclk              <- /sys/class/drm/card0/device/pp_dpm_dclk
 amdgpu_set_pp_dpm_dclk              <- /sys/class/drm/card0/device/pp_dpm_dclk
 amdgpu_get_pp_power_profile_mode    <- /sys/class/drm/card0/device/pp_power_profile_mode
 amdgpu_set_pp_power_profile_mode    <- /sys/class/drm/card0/device/pp_power_profile_mode
 amdgpu_get_gpu_metrics              <- /sys/class/drm/card0/device/gpu_metrics
** 0007
 amdgpu_pm_compute_clocks            <- untested
 amdgpu_dpm_set_powergating_by_smu   <- untested
 amdgpu_dpm_get_mclk                 <- untested
 amdgpu_dpm_get_sclk                 <- untested
** 0008
 amdgpu_get_pp_od_clk_voltage                 <- /sys/class/drm/card0/device/pp_od_clk_voltage
 amdgpu_set_pp_od_clk_voltage                 <- /sys/class/drm/card0/device/pp_od_clk_voltage
 amdgpu_set_pp_table                          <- /sys/class/drm/card0/device/pp_table
 amdgpu_set_power_dpm_force_performance_level <- /sys/class/drm/card0/device/power_dpm_force_performance_level

=== Summary of Untested Functions ===
** 0002
 amdgpu_dpm_mode2_reset                <- untested: needs Arctic Islands Hardware (VEGAx, RAVEN)
 amdgpu_dpm_switch_power_profile       <- untested: called during initialization
 amdgpu_dpm_set_xgmi_pstate            <- untested: amdgpu_xgmi_set_pstate():411 pstate switching disabled
 amdgpu_dpm_set_df_cstate              <- untested: needs ras enabled hardware
 amdgpu_dpm_enable_mgpu_fan_boost      <- untested: needs multi-gpu hardware
** 0005
 amdgpu_dpm_baco_enter                  <- untested: called from runtime.pm 
 amdgpu_dpm_baco_exit                   <- untested: called from runtime.pm 
 amdgpu_dpm_is_baco_supported           <- untested: needs other Hardware(cik, vi, soc15)
 amdgpu_dpm_baco_reset                  <- untested: needs other Hardware(cik, vi, soc15)
 amdgpu_get_pp_dpm_vclk                 <- untested: needs other Hardware
 amdgpu_set_pp_dpm_vclk                 <- untested: needs other Hardware
 amdgpu_get_pp_dpm_dclk                 <- untested: needs other Hardware
 amdgpu_set_pp_dpm_dclk                 <- untested: needs other Hardware
** 0007
 amdgpu_pm_compute_clocks            <- untested
 amdgpu_dpm_set_powergating_by_smu   <- untested
 amdgpu_dpm_get_mclk                 <- untested
 amdgpu_dpm_get_sclk                 <- untested
** 0008
 amdgpu_get_pp_od_clk_voltage                 <- file not found
 amdgpu_set_pp_od_clk_voltage                 <- file not found
 amdgpu_set_pp_table                          <- no binary data to test with


Darren Powell (8):
  amdgpu/pm: Powerplay API for smu , added get_performance_level
  amdgpu/pm: Powerplay API for smu , changed 6 dpm reset functions to
    use API
  amdgpu/pm: Powerplay API for smu , changed 6 pm hwmon fan functions to
    use API
  amdgpu/pm: Powerplay API for smu , changed 9 pm power functions to use
    API
  amdgpu/pm: Powerplay API for smu , changed 5 dpm powergating & sensor
    functions to use API
  amdgpu/pm: Powerplay API for smu , changes to clock and profile mode
    functions
  amdgpu/pm: Powerplay API for smu , changed 4 dpm functions to use API
  amdgpu/pm: Powerplay API for smu , updates to some pm functions

 .../gpu/drm/amd/include/kgd_pp_interface.h    |   4 +
 drivers/gpu/drm/amd/pm/amdgpu_dpm.c           | 228 ++----
 drivers/gpu/drm/amd/pm/amdgpu_pm.c            | 707 ++++--------------
 drivers/gpu/drm/amd/pm/inc/amdgpu_smu.h       |  73 +-
 drivers/gpu/drm/amd/pm/swsmu/amdgpu_smu.c     | 366 +++++++--
 5 files changed, 557 insertions(+), 821 deletions(-)


base-commit: 317990c7e076a0f4e4f0c3878e7e74f267ee029a
-- 
2.25.1

_______________________________________________
amd-gfx mailing list
amd-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/amd-gfx



[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux