RE: [PATCH 09/22] drm/amd/pm: check specific index for smu13

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



[AMD Official Use Only - General]

HI Tim

-----Original Message-----
From: Huang, Tim <Tim.Huang@xxxxxxx>
Sent: Friday, May 10, 2024 2:37 PM
To: Zhang, Jesse(Jie) <Jesse.Zhang@xxxxxxx>; amd-gfx@xxxxxxxxxxxxxxxxxxxxx
Cc: Deucher, Alexander <Alexander.Deucher@xxxxxxx>; Koenig, Christian <Christian.Koenig@xxxxxxx>; Zhang, Jesse(Jie) <Jesse.Zhang@xxxxxxx>; Zhang, Jesse(Jie) <Jesse.Zhang@xxxxxxx>
Subject: RE: [PATCH 09/22] drm/amd/pm: check specific index for smu13

[AMD Official Use Only - General]

Hi Jesse,

> -----Original Message-----
> From: amd-gfx <amd-gfx-bounces@xxxxxxxxxxxxxxxxxxxxx> On Behalf Of
> Jesse Zhang
> Sent: Friday, May 10, 2024 10:50 AM
> To: amd-gfx@xxxxxxxxxxxxxxxxxxxxx
> Cc: Deucher, Alexander <Alexander.Deucher@xxxxxxx>; Koenig, Christian
> <Christian.Koenig@xxxxxxx>; Huang, Tim <Tim.Huang@xxxxxxx>; Zhang,
> Jesse(Jie) <Jesse.Zhang@xxxxxxx>; Zhang, Jesse(Jie)
> <Jesse.Zhang@xxxxxxx>
> Subject: [PATCH 09/22] drm/amd/pm: check specific index for smu13
>
> Check for specific indexes that may be invalid values.
>
> Signed-off-by: Jesse Zhang <Jesse.Zhang@xxxxxxx>
> ---
>  drivers/gpu/drm/amd/pm/swsmu/smu13/smu_v13_0_6_ppt.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> 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 051092f1b1b4..7c343dd12a7f 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
> @@ -2336,6 +2336,8 @@ static int smu_v13_0_6_mode2_reset(struct
> smu_context *smu)
>
>       index = smu_cmn_to_asic_specific_index(smu,
> CMN2ASIC_MAPPING_MSG,
>
> SMU_MSG_GfxDeviceDriverReset);
> +     if (index < 0)
> +             ret = -EINVAL;

We should need to return the index here?
[Zhang, Jesse(Jie)] Thanks Tim. Yes, I will  another patch for it .

Tim

>
>       mutex_lock(&smu->message_lock);
>
> --
> 2.25.1






[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux