[PATCH 1/2] drm/amdgpu/pm: Add default case for smu IH process func

Alex Deucher alexdeucher at gmail.com
Mon Jan 22 14:30:47 UTC 2024


On Mon, Jan 22, 2024 at 3:52 AM Ma Jun <Jun.Ma2 at amd.com> wrote:
>
> Add default case for smu IH process func.
>
> Signed-off-by: Ma Jun <Jun.Ma2 at amd.com>
> ---
>  drivers/gpu/drm/amd/pm/swsmu/smu11/smu_v11_0.c       | 4 ++++
>  drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c       | 4 ++++
>  drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c | 5 ++++-
>  3 files changed, 12 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu11/smu_v11_0.c b/drivers/gpu/drm/amd/pm/swsmu/smu11/smu_v11_0.c
> index 8047150fddd4..d74343adaa5f 100644
> --- a/drivers/gpu/drm/amd/pm/swsmu/smu11/smu_v11_0.c
> +++ b/drivers/gpu/drm/amd/pm/swsmu/smu11/smu_v11_0.c
> @@ -1462,6 +1462,10 @@ static int smu_v11_0_irq_process(struct amdgpu_device *adev,
>                                         schedule_work(&smu->throttling_logging_work);
>
>                                 break;
> +                       default:
> +                               dev_dbg(adev->dev, "Unhandled contxt id %d from client:%d!\n",
> +                                                                       ctxid, client_id);

Typo: contxt -> context.  Same issue in the other files as well.  With
those fixed:
Reviewed-by: Alex Deucher <alexander.deucher at amd.com>

> +                               break;
>                         }
>                 }
>         }
> diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c b/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c
> index ff1f35e823a2..fc7c04e19b18 100644
> --- a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c
> +++ b/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0.c
> @@ -1428,6 +1428,10 @@ static int smu_v13_0_irq_process(struct amdgpu_device *adev,
>                                 data = data & (~THM_THERMAL_INT_CTRL__THERM_TRIGGER_MASK_MASK);
>                                 WREG32_SOC15(THM, 0, regTHM_THERMAL_INT_CTRL, data);
>                                 break;
> +                       default:
> +                               dev_dbg(adev->dev, "Unhandled contxt id %d from client:%d!\n",
> +                                                                       ctxid, client_id);
> +                               break;
>                         }
>                 }
>         }
> diff --git a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c b/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c
> index 952a983da49a..bc1242477002 100644
> --- a/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c
> +++ b/drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c
> @@ -1439,7 +1439,10 @@ static int smu_v13_0_6_irq_process(struct amdgpu_device *adev,
>                                                         entry->src_data[1]);
>                                         schedule_work(&smu->throttling_logging_work);
>                                 }
> -
> +                               break;
> +                       default:
> +                               dev_dbg(adev->dev, "Unhandled contxt id %d from client:%d!\n",
> +                                                                       ctxid, client_id);
>                                 break;
>                         }
>                 }
> --
> 2.34.1
>


More information about the amd-gfx mailing list