From: Prike Liang Date: Thu, 17 Oct 2024 06:54:31 +0000 (+0800) Subject: drm/amdgpu: Dereference the ATCS ACPI buffer X-Git-Tag: v6.13-rc1~122^2~15^2~12 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=32e7ee293ff476c67b51be006e986021967bc525;p=thirdparty%2Fkernel%2Flinux.git drm/amdgpu: Dereference the ATCS ACPI buffer Need to dereference the atcs acpi buffer after the method is executed, otherwise it will result in a memory leak. Signed-off-by: Prike Liang Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c index 1f5a296f5ed2f..cce85389427f3 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_acpi.c @@ -800,6 +800,7 @@ int amdgpu_acpi_power_shift_control(struct amdgpu_device *adev, return -EIO; } + kfree(info); return 0; }