diff options
author | Monk Liu <Monk.Liu@amd.com> | 2016-05-27 14:09:06 +0300 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2016-06-09 17:49:03 +0300 |
commit | 61da601b95cd5565d047e42e73f984f5bdfbba70 (patch) | |
tree | 2f95096dda49290d48d79da51cba7fbe8882f252 /drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c | |
parent | 3a3e88804d44e41ef2182d2a6577a6803fdd9ee0 (diff) | |
download | linux-61da601b95cd5565d047e42e73f984f5bdfbba70.tar.xz |
drm/amdgpu: fix mem leak in pplib/hwmgr
Signed-off-by: Monk Liu <Monk.Liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c')
-rw-r--r-- | drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c index 1c48917da3cf..910d56dcd7b1 100644 --- a/drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/hwmgr.c @@ -93,6 +93,13 @@ int hwmgr_fini(struct pp_hwmgr *hwmgr) if (hwmgr == NULL || hwmgr->ps == NULL) return -EINVAL; + /* do hwmgr finish*/ + kfree(hwmgr->backend); + + kfree(hwmgr->start_thermal_controller.function_list); + + kfree(hwmgr->set_temperature_range.function_list); + kfree(hwmgr->ps); kfree(hwmgr); return 0; |