mirror of
https://github.com/torvalds/linux.git
synced 2026-06-01 02:53:36 +02:00
drm/amd/display: Free memory allocation
[WHY] Free memory to avoid memory leak Reviewed-by: Joshua Aberback <joshua.aberback@amd.com> Signed-off-by: Clayton King <clayton.king@amd.com> Signed-off-by: Ivan Lipski <ivan.lipski@amd.com> Tested-by: Daniel Wheeler <daniel.wheeler@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
1f26214d26
commit
fa699acb8e
|
|
@ -1606,7 +1606,7 @@ struct clk_mgr_internal *dcn401_clk_mgr_construct(
|
|||
clk_mgr->base.bw_params = kzalloc(sizeof(*clk_mgr->base.bw_params), GFP_KERNEL);
|
||||
if (!clk_mgr->base.bw_params) {
|
||||
BREAK_TO_DEBUGGER();
|
||||
kfree(clk_mgr);
|
||||
kfree(clk_mgr401);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
@ -1617,6 +1617,7 @@ struct clk_mgr_internal *dcn401_clk_mgr_construct(
|
|||
if (!clk_mgr->wm_range_table) {
|
||||
BREAK_TO_DEBUGGER();
|
||||
kfree(clk_mgr->base.bw_params);
|
||||
kfree(clk_mgr401);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user