drm/amdgpu/swsmu: add get_fan_parameters callbacks for smu11 asics
grab the value from the pptable. Reviewed-by: Evan Quan <evan.quan@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
337b57aecb
commit
3204ff3e08
@ -1148,6 +1148,15 @@ static int arcturus_get_fan_speed_percent(struct smu_context *smu,
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int arcturus_get_fan_parameters(struct smu_context *smu)
|
||||||
|
{
|
||||||
|
PPTable_t *pptable = smu->smu_table.driver_pptable;
|
||||||
|
|
||||||
|
smu->fan_max_rpm = pptable->FanMaximumRpm;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
static int arcturus_get_power_limit(struct smu_context *smu)
|
static int arcturus_get_power_limit(struct smu_context *smu)
|
||||||
{
|
{
|
||||||
struct smu_11_0_powerplay_table *powerplay_table =
|
struct smu_11_0_powerplay_table *powerplay_table =
|
||||||
@ -2397,6 +2406,7 @@ static const struct pptable_funcs arcturus_ppt_funcs = {
|
|||||||
.get_gpu_metrics = arcturus_get_gpu_metrics,
|
.get_gpu_metrics = arcturus_get_gpu_metrics,
|
||||||
.gfx_ulv_control = smu_v11_0_gfx_ulv_control,
|
.gfx_ulv_control = smu_v11_0_gfx_ulv_control,
|
||||||
.deep_sleep_control = smu_v11_0_deep_sleep_control,
|
.deep_sleep_control = smu_v11_0_deep_sleep_control,
|
||||||
|
.get_fan_parameters = arcturus_get_fan_parameters,
|
||||||
};
|
};
|
||||||
|
|
||||||
void arcturus_set_ppt_funcs(struct smu_context *smu)
|
void arcturus_set_ppt_funcs(struct smu_context *smu)
|
||||||
|
@ -1385,6 +1385,15 @@ static int navi10_get_fan_speed_percent(struct smu_context *smu,
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int navi10_get_fan_parameters(struct smu_context *smu)
|
||||||
|
{
|
||||||
|
PPTable_t *pptable = smu->smu_table.driver_pptable;
|
||||||
|
|
||||||
|
smu->fan_max_rpm = pptable->FanMaximumRpm;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
static int navi10_get_power_profile_mode(struct smu_context *smu, char *buf)
|
static int navi10_get_power_profile_mode(struct smu_context *smu, char *buf)
|
||||||
{
|
{
|
||||||
DpmActivityMonitorCoeffInt_t activity_monitor;
|
DpmActivityMonitorCoeffInt_t activity_monitor;
|
||||||
@ -2666,6 +2675,7 @@ static const struct pptable_funcs navi10_ppt_funcs = {
|
|||||||
.enable_mgpu_fan_boost = navi10_enable_mgpu_fan_boost,
|
.enable_mgpu_fan_boost = navi10_enable_mgpu_fan_boost,
|
||||||
.gfx_ulv_control = smu_v11_0_gfx_ulv_control,
|
.gfx_ulv_control = smu_v11_0_gfx_ulv_control,
|
||||||
.deep_sleep_control = smu_v11_0_deep_sleep_control,
|
.deep_sleep_control = smu_v11_0_deep_sleep_control,
|
||||||
|
.get_fan_parameters = navi10_get_fan_parameters,
|
||||||
};
|
};
|
||||||
|
|
||||||
void navi10_set_ppt_funcs(struct smu_context *smu)
|
void navi10_set_ppt_funcs(struct smu_context *smu)
|
||||||
|
@ -1192,6 +1192,15 @@ static int sienna_cichlid_get_fan_speed_percent(struct smu_context *smu,
|
|||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static int sienna_cichlid_get_fan_parameters(struct smu_context *smu)
|
||||||
|
{
|
||||||
|
PPTable_t *pptable = smu->smu_table.driver_pptable;
|
||||||
|
|
||||||
|
smu->fan_max_rpm = pptable->FanMaximumRpm;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
static int sienna_cichlid_get_power_profile_mode(struct smu_context *smu, char *buf)
|
static int sienna_cichlid_get_power_profile_mode(struct smu_context *smu, char *buf)
|
||||||
{
|
{
|
||||||
DpmActivityMonitorCoeffInt_t activity_monitor;
|
DpmActivityMonitorCoeffInt_t activity_monitor;
|
||||||
@ -2811,6 +2820,7 @@ static const struct pptable_funcs sienna_cichlid_ppt_funcs = {
|
|||||||
.enable_mgpu_fan_boost = sienna_cichlid_enable_mgpu_fan_boost,
|
.enable_mgpu_fan_boost = sienna_cichlid_enable_mgpu_fan_boost,
|
||||||
.gfx_ulv_control = smu_v11_0_gfx_ulv_control,
|
.gfx_ulv_control = smu_v11_0_gfx_ulv_control,
|
||||||
.deep_sleep_control = smu_v11_0_deep_sleep_control,
|
.deep_sleep_control = smu_v11_0_deep_sleep_control,
|
||||||
|
.get_fan_parameters = sienna_cichlid_get_fan_parameters,
|
||||||
};
|
};
|
||||||
|
|
||||||
void sienna_cichlid_set_ppt_funcs(struct smu_context *smu)
|
void sienna_cichlid_set_ppt_funcs(struct smu_context *smu)
|
||||||
|
Loading…
Reference in New Issue
Block a user