diff options
author | Yue Hin Lau | 2017-10-24 17:40:50 +0200 |
---|---|---|
committer | Alex Deucher | 2017-12-04 22:41:38 +0100 |
commit | 75dbba34ae6df7bb63f0d836093a7e2d602da07d (patch) | |
tree | 5eb8d1482177ef3ffb8c38af61d78f3fe4faefcf /drivers/gpu/drm/amd/display/dc/dcn10 | |
parent | drm/amd/display: Move hdr_metadata from plane to stream (diff) | |
download | kernel-qcow2-linux-75dbba34ae6df7bb63f0d836093a7e2d602da07d.tar.gz kernel-qcow2-linux-75dbba34ae6df7bb63f0d836093a7e2d602da07d.tar.xz kernel-qcow2-linux-75dbba34ae6df7bb63f0d836093a7e2d602da07d.zip |
drm/amd/display: fix bug from last commit for hubbub
fix memory leak
Signed-off-by: Yue Hin Lau <Yuehin.Lau@amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng@amd.com>
Acked-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/dc/dcn10')
-rw-r--r-- | drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c b/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c index 256632cce520..dd834fdf7ce7 100644 --- a/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c +++ b/drivers/gpu/drm/amd/display/dc/dcn10/dcn10_resource.c @@ -730,6 +730,12 @@ static void destruct(struct dcn10_resource_pool *pool) kfree(TO_DCN10_MPC(pool->base.mpc)); pool->base.mpc = NULL; } + + if (pool->base.hubbub != NULL) { + kfree(pool->base.hubbub); + pool->base.hubbub = NULL; + } + for (i = 0; i < pool->base.pipe_count; i++) { if (pool->base.opps[i] != NULL) pool->base.opps[i]->funcs->opp_destroy(&pool->base.opps[i]); @@ -1453,7 +1459,7 @@ static bool construct( } pool->base.hubbub = dcn10_hubbub_create(ctx); - if (pool->base.mpc == NULL) { + if (pool->base.hubbub == NULL) { BREAK_TO_DEBUGGER(); dm_error("DC: failed to create mpc!\n"); goto fail; |