Re: [PATCH] drm/amdgpu: Fix a memory leak

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

 



On Fri, Sep 22, 2023 at 5:51 PM Luben Tuikov <luben.tuikov@xxxxxxx> wrote:
>
> Fix a memory leak in amdgpu_fru_get_product_info().
>
> Cc: Alex Deucher <Alexander.Deucher@xxxxxxx>
> Reported-by: Yang Wang <kevinyang.wang@xxxxxxx>
> Fixes: 0dbf2c56262532 ("drm/amdgpu: Interpret IPMI data for product information (v2)")

Reviewed-by: Alex Deucher <alexander.deucher@xxxxxxx>

> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_fru_eeprom.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_fru_eeprom.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_fru_eeprom.c
> index 9c66d98af6d86a..7cd0dfaeee206c 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_fru_eeprom.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_fru_eeprom.c
> @@ -170,6 +170,7 @@ int amdgpu_fru_get_product_info(struct amdgpu_device *adev)
>                 csum += pia[size - 1];
>         if (csum) {
>                 DRM_ERROR("Bad Product Info Area checksum: 0x%02x", csum);
> +               kfree(pia);
>                 return -EIO;
>         }
>
>
> base-commit: 14d13f757d369c9873ebbe34d02d0896f5de565e
> --
> 2.42.0
>




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

  Powered by Linux