Path: blob/master/drivers/gpu/drm/amd/pm/inc/amdgpu_dpm.h
26535 views
/*1* Copyright 2014 Advanced Micro Devices, Inc.2*3* Permission is hereby granted, free of charge, to any person obtaining a4* copy of this software and associated documentation files (the "Software"),5* to deal in the Software without restriction, including without limitation6* the rights to use, copy, modify, merge, publish, distribute, sublicense,7* and/or sell copies of the Software, and to permit persons to whom the8* Software is furnished to do so, subject to the following conditions:9*10* The above copyright notice and this permission notice shall be included in11* all copies or substantial portions of the Software.12*13* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR14* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,15* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL16* THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR17* OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,18* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR19* OTHER DEALINGS IN THE SOFTWARE.20*21*/22#ifndef __AMDGPU_DPM_H__23#define __AMDGPU_DPM_H__2425/* Argument for PPSMC_MSG_GpuChangeState */26enum gfx_change_state {27sGpuChangeState_D0Entry = 1,28sGpuChangeState_D3Entry,29};3031enum amdgpu_int_thermal_type {32THERMAL_TYPE_NONE,33THERMAL_TYPE_EXTERNAL,34THERMAL_TYPE_EXTERNAL_GPIO,35THERMAL_TYPE_RV6XX,36THERMAL_TYPE_RV770,37THERMAL_TYPE_ADT7473_WITH_INTERNAL,38THERMAL_TYPE_EVERGREEN,39THERMAL_TYPE_SUMO,40THERMAL_TYPE_NI,41THERMAL_TYPE_SI,42THERMAL_TYPE_EMC2103_WITH_INTERNAL,43THERMAL_TYPE_CI,44THERMAL_TYPE_KV,45};4647enum amdgpu_runpm_mode {48AMDGPU_RUNPM_NONE,49AMDGPU_RUNPM_PX,50AMDGPU_RUNPM_BOCO,51AMDGPU_RUNPM_BACO,52AMDGPU_RUNPM_BAMACO,53};5455#define BACO_SUPPORT (1<<0)56#define MACO_SUPPORT (1<<1)5758struct amdgpu_ps {59u32 caps; /* vbios flags */60u32 class; /* vbios flags */61u32 class2; /* vbios flags */62/* UVD clocks */63u32 vclk;64u32 dclk;65/* VCE clocks */66u32 evclk;67u32 ecclk;68bool vce_active;69enum amd_vce_level vce_level;70/* asic priv */71void *ps_priv;72};7374struct amdgpu_dpm_thermal {75/* thermal interrupt work */76struct work_struct work;77/* low temperature threshold */78int min_temp;79/* high temperature threshold */80int max_temp;81/* edge max emergency(shutdown) temp */82int max_edge_emergency_temp;83/* hotspot low temperature threshold */84int min_hotspot_temp;85/* hotspot high temperature critical threshold */86int max_hotspot_crit_temp;87/* hotspot max emergency(shutdown) temp */88int max_hotspot_emergency_temp;89/* memory low temperature threshold */90int min_mem_temp;91/* memory high temperature critical threshold */92int max_mem_crit_temp;93/* memory max emergency(shutdown) temp */94int max_mem_emergency_temp;95/* SWCTF threshold */96int sw_ctf_threshold;97/* was last interrupt low to high or high to low */98bool high_to_low;99/* interrupt source */100struct amdgpu_irq_src irq;101};102103struct amdgpu_clock_and_voltage_limits {104u32 sclk;105u32 mclk;106u16 vddc;107u16 vddci;108};109110struct amdgpu_clock_array {111u32 count;112u32 *values;113};114115struct amdgpu_clock_voltage_dependency_entry {116u32 clk;117u16 v;118};119120struct amdgpu_clock_voltage_dependency_table {121u32 count;122struct amdgpu_clock_voltage_dependency_entry *entries;123};124125union amdgpu_cac_leakage_entry {126struct {127u16 vddc;128u32 leakage;129};130struct {131u16 vddc1;132u16 vddc2;133u16 vddc3;134};135};136137struct amdgpu_cac_leakage_table {138u32 count;139union amdgpu_cac_leakage_entry *entries;140};141142struct amdgpu_phase_shedding_limits_entry {143u16 voltage;144u32 sclk;145u32 mclk;146};147148struct amdgpu_phase_shedding_limits_table {149u32 count;150struct amdgpu_phase_shedding_limits_entry *entries;151};152153struct amdgpu_uvd_clock_voltage_dependency_entry {154u32 vclk;155u32 dclk;156u16 v;157};158159struct amdgpu_uvd_clock_voltage_dependency_table {160u8 count;161struct amdgpu_uvd_clock_voltage_dependency_entry *entries;162};163164struct amdgpu_vce_clock_voltage_dependency_entry {165u32 ecclk;166u32 evclk;167u16 v;168};169170struct amdgpu_vce_clock_voltage_dependency_table {171u8 count;172struct amdgpu_vce_clock_voltage_dependency_entry *entries;173};174175struct amdgpu_ppm_table {176u8 ppm_design;177u16 cpu_core_number;178u32 platform_tdp;179u32 small_ac_platform_tdp;180u32 platform_tdc;181u32 small_ac_platform_tdc;182u32 apu_tdp;183u32 dgpu_tdp;184u32 dgpu_ulv_power;185u32 tj_max;186};187188struct amdgpu_cac_tdp_table {189u16 tdp;190u16 configurable_tdp;191u16 tdc;192u16 battery_power_limit;193u16 small_power_limit;194u16 low_cac_leakage;195u16 high_cac_leakage;196u16 maximum_power_delivery_limit;197};198199struct amdgpu_dpm_dynamic_state {200struct amdgpu_clock_voltage_dependency_table vddc_dependency_on_sclk;201struct amdgpu_clock_voltage_dependency_table vddci_dependency_on_mclk;202struct amdgpu_clock_voltage_dependency_table vddc_dependency_on_mclk;203struct amdgpu_clock_voltage_dependency_table mvdd_dependency_on_mclk;204struct amdgpu_clock_voltage_dependency_table vddc_dependency_on_dispclk;205struct amdgpu_uvd_clock_voltage_dependency_table uvd_clock_voltage_dependency_table;206struct amdgpu_vce_clock_voltage_dependency_table vce_clock_voltage_dependency_table;207struct amdgpu_clock_voltage_dependency_table samu_clock_voltage_dependency_table;208struct amdgpu_clock_voltage_dependency_table acp_clock_voltage_dependency_table;209struct amdgpu_clock_voltage_dependency_table vddgfx_dependency_on_sclk;210struct amdgpu_clock_array valid_sclk_values;211struct amdgpu_clock_array valid_mclk_values;212struct amdgpu_clock_and_voltage_limits max_clock_voltage_on_dc;213struct amdgpu_clock_and_voltage_limits max_clock_voltage_on_ac;214u32 mclk_sclk_ratio;215u32 sclk_mclk_delta;216u16 vddc_vddci_delta;217u16 min_vddc_for_pcie_gen2;218struct amdgpu_cac_leakage_table cac_leakage_table;219struct amdgpu_phase_shedding_limits_table phase_shedding_limits_table;220struct amdgpu_ppm_table *ppm_table;221struct amdgpu_cac_tdp_table *cac_tdp_table;222};223224struct amdgpu_dpm_fan {225u16 t_min;226u16 t_med;227u16 t_high;228u16 pwm_min;229u16 pwm_med;230u16 pwm_high;231u8 t_hyst;232u32 cycle_delay;233u16 t_max;234u8 control_mode;235u16 default_max_fan_pwm;236u16 default_fan_output_sensitivity;237u16 fan_output_sensitivity;238bool ucode_fan_control;239};240241struct amdgpu_dpm {242struct amdgpu_ps *ps;243/* number of valid power states */244int num_ps;245/* current power state that is active */246struct amdgpu_ps *current_ps;247/* requested power state */248struct amdgpu_ps *requested_ps;249/* boot up power state */250struct amdgpu_ps *boot_ps;251/* default uvd power state */252struct amdgpu_ps *uvd_ps;253/* vce requirements */254u32 num_of_vce_states;255struct amd_vce_state vce_states[AMD_MAX_VCE_LEVELS];256enum amd_vce_level vce_level;257enum amd_pm_state_type state;258enum amd_pm_state_type user_state;259enum amd_pm_state_type last_state;260enum amd_pm_state_type last_user_state;261u32 platform_caps;262u32 voltage_response_time;263u32 backbias_response_time;264void *priv;265u32 new_active_crtcs;266int new_active_crtc_count;267u32 current_active_crtcs;268int current_active_crtc_count;269struct amdgpu_dpm_dynamic_state dyn_state;270struct amdgpu_dpm_fan fan;271u32 tdp_limit;272u32 near_tdp_limit;273u32 near_tdp_limit_adjusted;274u32 sq_ramping_threshold;275u32 cac_leakage;276u16 tdp_od_limit;277u32 tdp_adjustment;278u16 load_line_slope;279bool power_control;280/* special states active */281bool thermal_active;282bool uvd_active;283bool vce_active;284/* thermal handling */285struct amdgpu_dpm_thermal thermal;286/* forced levels */287enum amd_dpm_forced_level forced_level;288};289290enum ip_power_state {291POWER_STATE_UNKNOWN,292POWER_STATE_ON,293POWER_STATE_OFF,294};295296/* Used to mask smu debug modes */297#define SMU_DEBUG_HALT_ON_ERROR BIT(0)298#define SMU_DEBUG_POOL_USE_VRAM BIT(1)299300#define MAX_SMU_I2C_BUSES 2301302struct amdgpu_smu_i2c_bus {303struct i2c_adapter adapter;304struct amdgpu_device *adev;305int port;306struct mutex mutex;307};308309struct config_table_setting310{311uint16_t gfxclk_average_tau;312uint16_t socclk_average_tau;313uint16_t uclk_average_tau;314uint16_t gfx_activity_average_tau;315uint16_t mem_activity_average_tau;316uint16_t socket_power_average_tau;317uint16_t apu_socket_power_average_tau;318uint16_t fclk_average_tau;319};320321#define OD_OPS_SUPPORT_FAN_CURVE_RETRIEVE BIT(0)322#define OD_OPS_SUPPORT_FAN_CURVE_SET BIT(1)323#define OD_OPS_SUPPORT_ACOUSTIC_LIMIT_THRESHOLD_RETRIEVE BIT(2)324#define OD_OPS_SUPPORT_ACOUSTIC_LIMIT_THRESHOLD_SET BIT(3)325#define OD_OPS_SUPPORT_ACOUSTIC_TARGET_THRESHOLD_RETRIEVE BIT(4)326#define OD_OPS_SUPPORT_ACOUSTIC_TARGET_THRESHOLD_SET BIT(5)327#define OD_OPS_SUPPORT_FAN_TARGET_TEMPERATURE_RETRIEVE BIT(6)328#define OD_OPS_SUPPORT_FAN_TARGET_TEMPERATURE_SET BIT(7)329#define OD_OPS_SUPPORT_FAN_MINIMUM_PWM_RETRIEVE BIT(8)330#define OD_OPS_SUPPORT_FAN_MINIMUM_PWM_SET BIT(9)331#define OD_OPS_SUPPORT_FAN_ZERO_RPM_ENABLE_RETRIEVE BIT(10)332#define OD_OPS_SUPPORT_FAN_ZERO_RPM_ENABLE_SET BIT(11)333#define OD_OPS_SUPPORT_FAN_ZERO_RPM_STOP_TEMP_RETRIEVE BIT(12)334#define OD_OPS_SUPPORT_FAN_ZERO_RPM_STOP_TEMP_SET BIT(13)335336struct amdgpu_pm {337struct mutex mutex;338u32 current_sclk;339u32 current_mclk;340u32 default_sclk;341u32 default_mclk;342struct amdgpu_i2c_chan *i2c_bus;343bool bus_locked;344/* internal thermal controller on rv6xx+ */345enum amdgpu_int_thermal_type int_thermal_type;346struct device *int_hwmon_dev;347/* fan control parameters */348bool no_fan;349u8 fan_pulses_per_revolution;350u8 fan_min_rpm;351u8 fan_max_rpm;352/* dpm */353bool dpm_enabled;354bool sysfs_initialized;355struct amdgpu_dpm dpm;356const struct firmware *fw; /* SMC firmware */357uint32_t fw_version;358uint32_t pcie_gen_mask;359uint32_t pcie_mlw_mask;360struct amd_pp_display_configuration pm_display_cfg;/* set by dc */361uint32_t smu_prv_buffer_size;362struct amdgpu_bo *smu_prv_buffer;363bool ac_power;364/* powerplay feature */365uint32_t pp_feature;366367/* Used for I2C access to various EEPROMs on relevant ASICs */368struct amdgpu_smu_i2c_bus smu_i2c[MAX_SMU_I2C_BUSES];369struct i2c_adapter *ras_eeprom_i2c_bus;370struct i2c_adapter *fru_eeprom_i2c_bus;371struct list_head pm_attr_list;372373atomic_t pwr_state[AMD_IP_BLOCK_TYPE_NUM];374375/*376* 0 = disabled (default), otherwise enable corresponding debug mode377*/378uint32_t smu_debug_mask;379380bool pp_force_state_enabled;381382struct mutex stable_pstate_ctx_lock;383struct amdgpu_ctx *stable_pstate_ctx;384385struct config_table_setting config_table;386/* runtime mode */387enum amdgpu_runpm_mode rpm_mode;388389struct list_head od_kobj_list;390uint32_t od_feature_mask;391};392393int amdgpu_dpm_read_sensor(struct amdgpu_device *adev, enum amd_pp_sensors sensor,394void *data, uint32_t *size);395396int amdgpu_dpm_get_apu_thermal_limit(struct amdgpu_device *adev, uint32_t *limit);397int amdgpu_dpm_set_apu_thermal_limit(struct amdgpu_device *adev, uint32_t limit);398399int amdgpu_dpm_set_powergating_by_smu(struct amdgpu_device *adev,400uint32_t block_type, bool gate, int inst);401402extern int amdgpu_dpm_get_sclk(struct amdgpu_device *adev, bool low);403404extern int amdgpu_dpm_get_mclk(struct amdgpu_device *adev, bool low);405406int amdgpu_dpm_set_xgmi_pstate(struct amdgpu_device *adev,407uint32_t pstate);408409int amdgpu_dpm_switch_power_profile(struct amdgpu_device *adev,410enum PP_SMC_POWER_PROFILE type,411bool en);412int amdgpu_dpm_pause_power_profile(struct amdgpu_device *adev,413bool pause);414415int amdgpu_dpm_baco_reset(struct amdgpu_device *adev);416417int amdgpu_dpm_mode2_reset(struct amdgpu_device *adev);418int amdgpu_dpm_link_reset(struct amdgpu_device *adev);419int amdgpu_dpm_enable_gfx_features(struct amdgpu_device *adev);420421int amdgpu_dpm_is_baco_supported(struct amdgpu_device *adev);422423bool amdgpu_dpm_is_mode1_reset_supported(struct amdgpu_device *adev);424bool amdgpu_dpm_is_link_reset_supported(struct amdgpu_device *adev);425int amdgpu_dpm_mode1_reset(struct amdgpu_device *adev);426427int amdgpu_dpm_set_mp1_state(struct amdgpu_device *adev,428enum pp_mp1_state mp1_state);429430int amdgpu_dpm_notify_rlc_state(struct amdgpu_device *adev, bool en);431432int amdgpu_dpm_set_gfx_power_up_by_imu(struct amdgpu_device *adev);433434int amdgpu_dpm_baco_exit(struct amdgpu_device *adev);435436int amdgpu_dpm_baco_enter(struct amdgpu_device *adev);437438int amdgpu_dpm_set_df_cstate(struct amdgpu_device *adev,439uint32_t cstate);440441int amdgpu_dpm_enable_mgpu_fan_boost(struct amdgpu_device *adev);442443int amdgpu_dpm_set_clockgating_by_smu(struct amdgpu_device *adev,444uint32_t msg_id);445446int amdgpu_dpm_smu_i2c_bus_access(struct amdgpu_device *adev,447bool acquire);448449void amdgpu_pm_acpi_event_handler(struct amdgpu_device *adev);450451void amdgpu_dpm_compute_clocks(struct amdgpu_device *adev);452void amdgpu_dpm_enable_uvd(struct amdgpu_device *adev, bool enable);453void amdgpu_dpm_enable_vcn(struct amdgpu_device *adev, bool enable, int inst);454void amdgpu_dpm_enable_vce(struct amdgpu_device *adev, bool enable);455void amdgpu_dpm_enable_jpeg(struct amdgpu_device *adev, bool enable);456void amdgpu_dpm_enable_vpe(struct amdgpu_device *adev, bool enable);457int amdgpu_pm_load_smu_firmware(struct amdgpu_device *adev, uint32_t *smu_version);458int amdgpu_dpm_handle_passthrough_sbr(struct amdgpu_device *adev, bool enable);459int amdgpu_dpm_send_hbm_bad_pages_num(struct amdgpu_device *adev, uint32_t size);460int amdgpu_dpm_send_hbm_bad_channel_flag(struct amdgpu_device *adev, uint32_t size);461int amdgpu_dpm_send_rma_reason(struct amdgpu_device *adev);462int amdgpu_dpm_get_dpm_freq_range(struct amdgpu_device *adev,463enum pp_clock_type type,464uint32_t *min,465uint32_t *max);466int amdgpu_dpm_set_soft_freq_range(struct amdgpu_device *adev,467enum pp_clock_type type,468uint32_t min,469uint32_t max);470int amdgpu_dpm_write_watermarks_table(struct amdgpu_device *adev);471int amdgpu_dpm_wait_for_event(struct amdgpu_device *adev, enum smu_event_type event,472uint64_t event_arg);473int amdgpu_dpm_get_residency_gfxoff(struct amdgpu_device *adev, u32 *value);474int amdgpu_dpm_set_residency_gfxoff(struct amdgpu_device *adev, bool value);475int amdgpu_dpm_get_entrycount_gfxoff(struct amdgpu_device *adev, u64 *value);476int amdgpu_dpm_get_status_gfxoff(struct amdgpu_device *adev, uint32_t *value);477uint64_t amdgpu_dpm_get_thermal_throttling_counter(struct amdgpu_device *adev);478void amdgpu_dpm_gfx_state_change(struct amdgpu_device *adev,479enum gfx_change_state state);480int amdgpu_dpm_get_ecc_info(struct amdgpu_device *adev,481void *umc_ecc);482struct amd_vce_state *amdgpu_dpm_get_vce_clock_state(struct amdgpu_device *adev,483uint32_t idx);484void amdgpu_dpm_get_current_power_state(struct amdgpu_device *adev, enum amd_pm_state_type *state);485void amdgpu_dpm_set_power_state(struct amdgpu_device *adev,486enum amd_pm_state_type state);487enum amd_dpm_forced_level amdgpu_dpm_get_performance_level(struct amdgpu_device *adev);488int amdgpu_dpm_force_performance_level(struct amdgpu_device *adev,489enum amd_dpm_forced_level level);490int amdgpu_dpm_get_pp_num_states(struct amdgpu_device *adev,491struct pp_states_info *states);492int amdgpu_dpm_dispatch_task(struct amdgpu_device *adev,493enum amd_pp_task task_id,494enum amd_pm_state_type *user_state);495int amdgpu_dpm_get_pp_table(struct amdgpu_device *adev, char **table);496int amdgpu_dpm_set_fine_grain_clk_vol(struct amdgpu_device *adev,497uint32_t type,498long *input,499uint32_t size);500int amdgpu_dpm_odn_edit_dpm_table(struct amdgpu_device *adev,501uint32_t type,502long *input,503uint32_t size);504int amdgpu_dpm_print_clock_levels(struct amdgpu_device *adev,505enum pp_clock_type type,506char *buf);507int amdgpu_dpm_emit_clock_levels(struct amdgpu_device *adev,508enum pp_clock_type type,509char *buf,510int *offset);511int amdgpu_dpm_set_ppfeature_status(struct amdgpu_device *adev,512uint64_t ppfeature_masks);513int amdgpu_dpm_get_ppfeature_status(struct amdgpu_device *adev, char *buf);514int amdgpu_dpm_force_clock_level(struct amdgpu_device *adev,515enum pp_clock_type type,516uint32_t mask);517int amdgpu_dpm_get_sclk_od(struct amdgpu_device *adev);518int amdgpu_dpm_set_sclk_od(struct amdgpu_device *adev, uint32_t value);519int amdgpu_dpm_get_mclk_od(struct amdgpu_device *adev);520int amdgpu_dpm_set_mclk_od(struct amdgpu_device *adev, uint32_t value);521int amdgpu_dpm_get_power_profile_mode(struct amdgpu_device *adev,522char *buf);523int amdgpu_dpm_set_power_profile_mode(struct amdgpu_device *adev,524long *input, uint32_t size);525int amdgpu_dpm_get_gpu_metrics(struct amdgpu_device *adev, void **table);526ssize_t amdgpu_dpm_get_xcp_metrics(struct amdgpu_device *adev, int xcp_id,527void *table);528529/**530* @get_pm_metrics: Get one snapshot of power management metrics from PMFW. The531* sample is copied to pm_metrics buffer. It's expected to be allocated by the532* caller and size of the allocated buffer is passed. Max size expected for a533* metrics sample is 4096 bytes.534*535* Return: Actual size of the metrics sample536*/537ssize_t amdgpu_dpm_get_pm_metrics(struct amdgpu_device *adev, void *pm_metrics,538size_t size);539540int amdgpu_dpm_get_fan_control_mode(struct amdgpu_device *adev,541uint32_t *fan_mode);542int amdgpu_dpm_set_fan_speed_pwm(struct amdgpu_device *adev,543uint32_t speed);544int amdgpu_dpm_get_fan_speed_pwm(struct amdgpu_device *adev,545uint32_t *speed);546int amdgpu_dpm_get_fan_speed_rpm(struct amdgpu_device *adev,547uint32_t *speed);548int amdgpu_dpm_set_fan_speed_rpm(struct amdgpu_device *adev,549uint32_t speed);550int amdgpu_dpm_set_fan_control_mode(struct amdgpu_device *adev,551uint32_t mode);552int amdgpu_dpm_get_power_limit(struct amdgpu_device *adev,553uint32_t *limit,554enum pp_power_limit_level pp_limit_level,555enum pp_power_type power_type);556int amdgpu_dpm_set_power_limit(struct amdgpu_device *adev,557uint32_t limit);558int amdgpu_dpm_is_cclk_dpm_supported(struct amdgpu_device *adev);559int amdgpu_dpm_debugfs_print_current_performance_level(struct amdgpu_device *adev,560struct seq_file *m);561int amdgpu_dpm_get_smu_prv_buf_details(struct amdgpu_device *adev,562void **addr,563size_t *size);564int amdgpu_dpm_is_overdrive_supported(struct amdgpu_device *adev);565int amdgpu_dpm_is_overdrive_enabled(struct amdgpu_device *adev);566int amdgpu_dpm_set_pp_table(struct amdgpu_device *adev,567const char *buf,568size_t size);569int amdgpu_dpm_get_num_cpu_cores(struct amdgpu_device *adev);570void amdgpu_dpm_stb_debug_fs_init(struct amdgpu_device *adev);571int amdgpu_dpm_display_configuration_change(struct amdgpu_device *adev,572const struct amd_pp_display_configuration *input);573int amdgpu_dpm_get_clock_by_type(struct amdgpu_device *adev,574enum amd_pp_clock_type type,575struct amd_pp_clocks *clocks);576int amdgpu_dpm_get_display_mode_validation_clks(struct amdgpu_device *adev,577struct amd_pp_simple_clock_info *clocks);578int amdgpu_dpm_get_clock_by_type_with_latency(struct amdgpu_device *adev,579enum amd_pp_clock_type type,580struct pp_clock_levels_with_latency *clocks);581int amdgpu_dpm_get_clock_by_type_with_voltage(struct amdgpu_device *adev,582enum amd_pp_clock_type type,583struct pp_clock_levels_with_voltage *clocks);584int amdgpu_dpm_set_watermarks_for_clocks_ranges(struct amdgpu_device *adev,585void *clock_ranges);586int amdgpu_dpm_display_clock_voltage_request(struct amdgpu_device *adev,587struct pp_display_clock_request *clock);588int amdgpu_dpm_get_current_clocks(struct amdgpu_device *adev,589struct amd_pp_clock_info *clocks);590void amdgpu_dpm_notify_smu_enable_pwe(struct amdgpu_device *adev);591int amdgpu_dpm_set_active_display_count(struct amdgpu_device *adev,592uint32_t count);593int amdgpu_dpm_set_min_deep_sleep_dcefclk(struct amdgpu_device *adev,594uint32_t clock);595void amdgpu_dpm_set_hard_min_dcefclk_by_freq(struct amdgpu_device *adev,596uint32_t clock);597void amdgpu_dpm_set_hard_min_fclk_by_freq(struct amdgpu_device *adev,598uint32_t clock);599int amdgpu_dpm_display_disable_memory_clock_switch(struct amdgpu_device *adev,600bool disable_memory_clock_switch);601int amdgpu_dpm_get_max_sustainable_clocks_by_dc(struct amdgpu_device *adev,602struct pp_smu_nv_clock_table *max_clocks);603enum pp_smu_status amdgpu_dpm_get_uclk_dpm_states(struct amdgpu_device *adev,604unsigned int *clock_values_in_khz,605unsigned int *num_states);606int amdgpu_dpm_get_dpm_clock_table(struct amdgpu_device *adev,607struct dpm_clocks *clock_table);608int amdgpu_dpm_set_pm_policy(struct amdgpu_device *adev, int policy_type,609int policy_level);610ssize_t amdgpu_dpm_get_pm_policy_info(struct amdgpu_device *adev,611enum pp_pm_policy p_type, char *buf);612int amdgpu_dpm_reset_sdma(struct amdgpu_device *adev, uint32_t inst_mask);613bool amdgpu_dpm_reset_sdma_is_supported(struct amdgpu_device *adev);614int amdgpu_dpm_reset_vcn(struct amdgpu_device *adev, uint32_t inst_mask);615616#endif617618619