On Tue, May 18, 2021 at 10:13 PM Alex Deucher <alexdeucher@xxxxxxxxx> wrote: > > Can also add: > Fixes: https://gitlab.freedesktop.org/drm/amd/-/issues/1580 er, Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/1580 > > Reviewed-by: Alex Deucher <alexander.deucher@xxxxxxx> > > Alex > > On Tue, May 18, 2021 at 10:12 PM Alex Deucher <alexdeucher@xxxxxxxxx> wrote: > > > > Do we need a similar check in the vega powerplay code? > > > > Alex > > > > > > On Mon, May 17, 2021 at 10:59 PM Feng, Kenneth <Kenneth.Feng@xxxxxxx> wrote: > > > > > > [AMD Official Use Only] > > > > > > Reviewed-by: Kenneth Feng <kenneth.feng@xxxxxxx> > > > > > > -----Original Message----- > > > From: Quan, Evan <Evan.Quan@xxxxxxx> > > > Sent: Tuesday, May 18, 2021 10:05 AM > > > To: amd-gfx@xxxxxxxxxxxxxxxxxxxxx > > > Cc: Deucher, Alexander <Alexander.Deucher@xxxxxxx>; Feng, Kenneth <Kenneth.Feng@xxxxxxx>; Quan, Evan <Evan.Quan@xxxxxxx> > > > Subject: [PATCH] drm/amd/pm: correct MGpuFanBoost setting > > > > > > No MGpuFanBoost setting for those ASICs which do not support it. > > > Otherwise, it may breaks their fan control feature. > > > > > > Change-Id: Ifa9c87ac537a07937a0f0f6a670f21368eb29218 > > > Signed-off-by: Evan Quan <evan.quan@xxxxxxx> > > > --- > > > drivers/gpu/drm/amd/pm/swsmu/smu11/navi10_ppt.c | 9 +++++++++ > > > .../gpu/drm/amd/pm/swsmu/smu11/sienna_cichlid_ppt.c | 10 ++++++++++ > > > 2 files changed, 19 insertions(+) > > > > > > diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu11/navi10_ppt.c b/drivers/gpu/drm/amd/pm/swsmu/smu11/navi10_ppt.c > > > index d2063b1e7936..f16c76038f13 100644 > > > --- a/drivers/gpu/drm/amd/pm/swsmu/smu11/navi10_ppt.c > > > +++ b/drivers/gpu/drm/amd/pm/swsmu/smu11/navi10_ppt.c > > > @@ -2936,6 +2936,8 @@ static ssize_t navi1x_get_gpu_metrics(struct smu_context *smu, > > > > > > static int navi10_enable_mgpu_fan_boost(struct smu_context *smu) { > > > + struct smu_table_context *table_context = &smu->smu_table; > > > + PPTable_t *smc_pptable = table_context->driver_pptable; > > > struct amdgpu_device *adev = smu->adev; > > > uint32_t param = 0; > > > > > > @@ -2943,6 +2945,13 @@ static int navi10_enable_mgpu_fan_boost(struct smu_context *smu) > > > if (adev->asic_type == CHIP_NAVI12) > > > return 0; > > > > > > + /* > > > + * Skip the MGpuFanBoost setting for those ASICs > > > + * which do not support it > > > + */ > > > + if (!smc_pptable->MGpuFanBoostLimitRpm) > > > + return 0; > > > + > > > /* Workaround for WS SKU */ > > > if (adev->pdev->device == 0x7312 && > > > adev->pdev->revision == 0) > > > diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu11/sienna_cichlid_ppt.c b/drivers/gpu/drm/amd/pm/swsmu/smu11/sienna_cichlid_ppt.c > > > index 3c3a7f9233e0..159cd698323e 100644 > > > --- a/drivers/gpu/drm/amd/pm/swsmu/smu11/sienna_cichlid_ppt.c > > > +++ b/drivers/gpu/drm/amd/pm/swsmu/smu11/sienna_cichlid_ppt.c > > > @@ -3201,6 +3201,16 @@ static ssize_t sienna_cichlid_get_gpu_metrics(struct smu_context *smu, > > > > > > static int sienna_cichlid_enable_mgpu_fan_boost(struct smu_context *smu) { > > > + struct smu_table_context *table_context = &smu->smu_table; > > > + PPTable_t *smc_pptable = table_context->driver_pptable; > > > + > > > + /* > > > + * Skip the MGpuFanBoost setting for those ASICs > > > + * which do not support it > > > + */ > > > + if (!smc_pptable->MGpuFanBoostLimitRpm) > > > + return 0; > > > + > > > return smu_cmn_send_smc_msg_with_param(smu, > > > SMU_MSG_SetMGpuFanBoostLimitRpm, > > > 0, > > > -- > > > 2.29.0 > > > _______________________________________________ > > > amd-gfx mailing list > > > amd-gfx@xxxxxxxxxxxxxxxxxxxxx > > > https://lists.freedesktop.org/mailman/listinfo/amd-gfx _______________________________________________ amd-gfx mailing list amd-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/amd-gfx