1
0
Fork 0
mirror of synced 2025-03-06 20:59:54 +01:00
linux/drivers/gpu/drm/amd/display/dc/dcn302
Anson Jacob 7b89bf8318 drm/amd/display: Fix multiple memory leaks reported by coverity
coccinelle patch used:

@@ expression enc1,vpg,afmt; @@
-       if (!enc1 || !vpg || !afmt)
+       if (!enc1 || !vpg || !afmt) {
+               kfree(enc1);
+               kfree(vpg);
+               kfree(afmt);
                return NULL;
+       }

Addresses-Coverity-ID: 1466017: ("Resource leaks")

Reviewed-by: Aurabindo Jayamohanan Pillai <Aurabindo.Pillai@amd.com>
Acked-by: Mikita Lipski <mikita.lipski@amd.com>
Signed-off-by: Anson Jacob <Anson.Jacob@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
2021-09-14 15:57:10 -04:00
..
dcn302_dccg.h drm/amd/display: Add support for DCN302 (v2) 2020-10-12 14:02:51 -04:00
dcn302_hwseq.c drm/amd/display: Control power gating by driver. 2021-06-08 12:16:14 -04:00
dcn302_hwseq.h drm/amd/display: Add support for DCN302 (v2) 2020-10-12 14:02:51 -04:00
dcn302_init.c drm/amd/display: Add support for DCN302 (v2) 2020-10-12 14:02:51 -04:00
dcn302_init.h drm/amd/display: Add support for DCN302 (v2) 2020-10-12 14:02:51 -04:00
dcn302_resource.c drm/amd/display: Fix multiple memory leaks reported by coverity 2021-09-14 15:57:10 -04:00
dcn302_resource.h drm/amd/display: fix initial bounding box values for dcn3.02 2021-02-02 12:10:56 -05:00
Makefile amdgpu: fix clang build warning 2021-01-25 17:48:46 -05:00