Skip to content

Commit 5d06167

Browse files
Luben Tuikovalexdeucher
authored andcommitted
drm/amdgpu: Fix a memory leak
Fix a memory leak in amdgpu_fru_get_product_info(). Cc: Alex Deucher <Alexander.Deucher@amd.com> Reported-by: Yang Wang <kevinyang.wang@amd.com> Fixes: 0dbf2c5 ("drm/amdgpu: Interpret IPMI data for product information (v2)") Signed-off-by: Luben Tuikov <luben.tuikov@amd.com> Reviewed-by: Alex Deucher <Alexander.Deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
1 parent 4953856 commit 5d06167

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

drivers/gpu/drm/amd/amdgpu/amdgpu_fru_eeprom.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,7 @@ int amdgpu_fru_get_product_info(struct amdgpu_device *adev)
170170
csum += pia[size - 1];
171171
if (csum) {
172172
DRM_ERROR("Bad Product Info Area checksum: 0x%02x", csum);
173+
kfree(pia);
173174
return -EIO;
174175
}
175176

0 commit comments

Comments
 (0)