* [PATCH] drm/amd/pm: correct MGpuFanBoost setting
@ 2021-05-18 2:05 Evan Quan
2021-05-18 2:59 ` Feng, Kenneth
0 siblings, 1 reply; 6+ messages in thread
From: Evan Quan @ 2021-05-18 2:05 UTC (permalink / raw)
To: amd-gfx; +Cc: Alexander.Deucher, Evan Quan, Kenneth.Feng
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@amd.com>
---
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@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
^ permalink raw reply related [flat|nested] 6+ messages in thread
* RE: [PATCH] drm/amd/pm: correct MGpuFanBoost setting
2021-05-18 2:05 [PATCH] drm/amd/pm: correct MGpuFanBoost setting Evan Quan
@ 2021-05-18 2:59 ` Feng, Kenneth
2021-05-19 2:12 ` Alex Deucher
0 siblings, 1 reply; 6+ messages in thread
From: Feng, Kenneth @ 2021-05-18 2:59 UTC (permalink / raw)
To: Quan, Evan, amd-gfx; +Cc: Deucher, Alexander
[AMD Official Use Only]
Reviewed-by: Kenneth Feng <kenneth.feng@amd.com>
-----Original Message-----
From: Quan, Evan <Evan.Quan@amd.com>
Sent: Tuesday, May 18, 2021 10:05 AM
To: amd-gfx@lists.freedesktop.org
Cc: Deucher, Alexander <Alexander.Deucher@amd.com>; Feng, Kenneth <Kenneth.Feng@amd.com>; Quan, Evan <Evan.Quan@amd.com>
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@amd.com>
---
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@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH] drm/amd/pm: correct MGpuFanBoost setting
2021-05-18 2:59 ` Feng, Kenneth
@ 2021-05-19 2:12 ` Alex Deucher
2021-05-19 2:13 ` Alex Deucher
2021-05-20 4:12 ` Quan, Evan
0 siblings, 2 replies; 6+ messages in thread
From: Alex Deucher @ 2021-05-19 2:12 UTC (permalink / raw)
To: Feng, Kenneth; +Cc: Deucher, Alexander, Quan, Evan, amd-gfx
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@amd.com> wrote:
>
> [AMD Official Use Only]
>
> Reviewed-by: Kenneth Feng <kenneth.feng@amd.com>
>
> -----Original Message-----
> From: Quan, Evan <Evan.Quan@amd.com>
> Sent: Tuesday, May 18, 2021 10:05 AM
> To: amd-gfx@lists.freedesktop.org
> Cc: Deucher, Alexander <Alexander.Deucher@amd.com>; Feng, Kenneth <Kenneth.Feng@amd.com>; Quan, Evan <Evan.Quan@amd.com>
> 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@amd.com>
> ---
> 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@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] drm/amd/pm: correct MGpuFanBoost setting
2021-05-19 2:12 ` Alex Deucher
@ 2021-05-19 2:13 ` Alex Deucher
2021-05-19 2:14 ` Alex Deucher
2021-05-20 4:12 ` Quan, Evan
1 sibling, 1 reply; 6+ messages in thread
From: Alex Deucher @ 2021-05-19 2:13 UTC (permalink / raw)
To: Feng, Kenneth; +Cc: Deucher, Alexander, Quan, Evan, amd-gfx
Can also add:
Fixes: https://gitlab.freedesktop.org/drm/amd/-/issues/1580
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Alex
On Tue, May 18, 2021 at 10:12 PM Alex Deucher <alexdeucher@gmail.com> 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@amd.com> wrote:
> >
> > [AMD Official Use Only]
> >
> > Reviewed-by: Kenneth Feng <kenneth.feng@amd.com>
> >
> > -----Original Message-----
> > From: Quan, Evan <Evan.Quan@amd.com>
> > Sent: Tuesday, May 18, 2021 10:05 AM
> > To: amd-gfx@lists.freedesktop.org
> > Cc: Deucher, Alexander <Alexander.Deucher@amd.com>; Feng, Kenneth <Kenneth.Feng@amd.com>; Quan, Evan <Evan.Quan@amd.com>
> > 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@amd.com>
> > ---
> > 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@lists.freedesktop.org
> > https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH] drm/amd/pm: correct MGpuFanBoost setting
2021-05-19 2:13 ` Alex Deucher
@ 2021-05-19 2:14 ` Alex Deucher
0 siblings, 0 replies; 6+ messages in thread
From: Alex Deucher @ 2021-05-19 2:14 UTC (permalink / raw)
To: Feng, Kenneth; +Cc: Deucher, Alexander, Quan, Evan, amd-gfx
On Tue, May 18, 2021 at 10:13 PM Alex Deucher <alexdeucher@gmail.com> 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@amd.com>
>
> Alex
>
> On Tue, May 18, 2021 at 10:12 PM Alex Deucher <alexdeucher@gmail.com> 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@amd.com> wrote:
> > >
> > > [AMD Official Use Only]
> > >
> > > Reviewed-by: Kenneth Feng <kenneth.feng@amd.com>
> > >
> > > -----Original Message-----
> > > From: Quan, Evan <Evan.Quan@amd.com>
> > > Sent: Tuesday, May 18, 2021 10:05 AM
> > > To: amd-gfx@lists.freedesktop.org
> > > Cc: Deucher, Alexander <Alexander.Deucher@amd.com>; Feng, Kenneth <Kenneth.Feng@amd.com>; Quan, Evan <Evan.Quan@amd.com>
> > > 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@amd.com>
> > > ---
> > > 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@lists.freedesktop.org
> > > https://lists.freedesktop.org/mailman/listinfo/amd-gfx
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [PATCH] drm/amd/pm: correct MGpuFanBoost setting
2021-05-19 2:12 ` Alex Deucher
2021-05-19 2:13 ` Alex Deucher
@ 2021-05-20 4:12 ` Quan, Evan
1 sibling, 0 replies; 6+ messages in thread
From: Quan, Evan @ 2021-05-20 4:12 UTC (permalink / raw)
To: Alex Deucher, Feng, Kenneth; +Cc: Deucher, Alexander, amd-gfx
Thanks. I will check and port this to powerplay code if necessary.
BR
Evan
> -----Original Message-----
> From: amd-gfx <amd-gfx-bounces@lists.freedesktop.org> On Behalf Of Alex
> Deucher
> Sent: Wednesday, May 19, 2021 10:13 AM
> To: Feng, Kenneth <Kenneth.Feng@amd.com>
> Cc: Deucher, Alexander <Alexander.Deucher@amd.com>; Quan, Evan
> <Evan.Quan@amd.com>; amd-gfx@lists.freedesktop.org
> Subject: Re: [PATCH] drm/amd/pm: correct MGpuFanBoost setting
>
> 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@amd.com> wrote:
> >
> > [AMD Official Use Only]
> >
> > Reviewed-by: Kenneth Feng <kenneth.feng@amd.com>
> >
> > -----Original Message-----
> > From: Quan, Evan <Evan.Quan@amd.com>
> > Sent: Tuesday, May 18, 2021 10:05 AM
> > To: amd-gfx@lists.freedesktop.org
> > Cc: Deucher, Alexander <Alexander.Deucher@amd.com>; Feng, Kenneth
> > <Kenneth.Feng@amd.com>; Quan, Evan <Evan.Quan@amd.com>
> > 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@amd.com>
> > ---
> > 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@lists.freedesktop.org
> > https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flist
> > s.freedesktop.org%2Fmailman%2Flistinfo%2Famd-
> gfx&data=04%7C01%7Cev
> >
> an.quan%40amd.com%7Ca14d02e9c00a4d13acf808d91a6b9da0%7C3dd8961f
> e4884e6
> >
> 08e11a82d994e183d%7C0%7C0%7C637569871776869665%7CUnknown%7CT
> WFpbGZsb3d
> >
> 8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%
> 3D%7C
> >
> 1000&sdata=oo3glBV4Par2AylocfT3586Y1U%2FuePBureFdUOu7j%2BQ%
> 3D&
> > reserved=0
> _______________________________________________
> amd-gfx mailing list
> amd-gfx@lists.freedesktop.org
> https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.
> freedesktop.org%2Fmailman%2Flistinfo%2Famd-
> gfx&data=04%7C01%7Cevan.quan%40amd.com%7Ca14d02e9c00a4d13a
> cf808d91a6b9da0%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C63
> 7569871776869665%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMD
> AiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=
> oo3glBV4Par2AylocfT3586Y1U%2FuePBureFdUOu7j%2BQ%3D&reserve
> d=0
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2021-05-20 4:12 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-18 2:05 [PATCH] drm/amd/pm: correct MGpuFanBoost setting Evan Quan
2021-05-18 2:59 ` Feng, Kenneth
2021-05-19 2:12 ` Alex Deucher
2021-05-19 2:13 ` Alex Deucher
2021-05-19 2:14 ` Alex Deucher
2021-05-20 4:12 ` Quan, Evan
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.