From: Christophe JAILLET Date: Sun, 7 Nov 2021 21:16:36 +0000 (+0100) Subject: gpu: host1x: Fix a memory leak in 'host1x_remove()' X-Git-Tag: v6.1-rc5~1719^2~14^2~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=025c6643a81564f066d8381b9e2f4603e0f8438f;p=platform%2Fkernel%2Flinux-starfive.git gpu: host1x: Fix a memory leak in 'host1x_remove()' Add a missing 'host1x_channel_list_free()' call in the remove function, as already done in the error handling path of the probe function. Fixes: 8474b02531c4 ("gpu: host1x: Refactor channel allocation code") Signed-off-by: Christophe JAILLET Signed-off-by: Thierry Reding --- diff --git a/drivers/gpu/host1x/dev.c b/drivers/gpu/host1x/dev.c index 9605495..80c685a 100644 --- a/drivers/gpu/host1x/dev.c +++ b/drivers/gpu/host1x/dev.c @@ -571,6 +571,7 @@ static int host1x_remove(struct platform_device *pdev) host1x_intr_deinit(host); host1x_syncpt_deinit(host); + host1x_channel_list_free(&host->channel_list); host1x_iommu_exit(host); host1x_bo_cache_destroy(&host->cache);