[PATCH 03/24] drm/amd/display: Memory was freed twice during disable

Harry Wentland harry.wentland at amd.com
Tue Apr 25 18:38:52 UTC 2017


From: Leon Elazar <leon.elazar at amd.com>

1. get_ss_info_from_atombios function was allocating the memory populating the provided pointer
but them freeing the memory.
Since the pointer was return as a valid value, we are trying to free the same memory during clock resource destruction

Change-Id: I225fb14741a30ca131aa7df179860c48964977eb
Signed-off-by: Leon Elazar <leon.elazar at amd.com>
Acked-by: Harry Wentland <Harry.Wentland at amd.com>
Reviewed-by: Tony Cheng <Tony.Cheng at amd.com>
---
 drivers/gpu/drm/amd/display/dc/dce/dce_clock_source.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_clock_source.c b/drivers/gpu/drm/amd/display/dc/dce/dce_clock_source.c
index 8ddad3a877d6..bd4524ef3a37 100644
--- a/drivers/gpu/drm/amd/display/dc/dce/dce_clock_source.c
+++ b/drivers/gpu/drm/amd/display/dc/dce/dce_clock_source.c
@@ -1035,7 +1035,6 @@ static void get_ss_info_from_atombios(
 	}
 
 	*spread_spectrum_data = ss_data;
-	dm_free(ss_data);
 	dm_free(ss_info);
 	return;
 
-- 
2.11.0



More information about the amd-gfx mailing list