[PATCH xf86-video-amdgpu 2/3] Call AMDGPUFreeRec from AMDGPUFreeScreen_KMS even if info == NULL

Michel Dänzer michel at daenzer.net
Mon Nov 2 01:30:40 PST 2015


From: Michel Dänzer <michel.daenzer at amd.com>

It's safe now.

Signed-off-by: Michel Dänzer <michel.daenzer at amd.com>
---
 src/amdgpu_kms.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/src/amdgpu_kms.c b/src/amdgpu_kms.c
index 41f01b3..fd89ba2 100644
--- a/src/amdgpu_kms.c
+++ b/src/amdgpu_kms.c
@@ -1031,15 +1031,10 @@ static Bool AMDGPUCloseScreen_KMS(CLOSE_SCREEN_ARGS_DECL)
 void AMDGPUFreeScreen_KMS(FREE_SCREEN_ARGS_DECL)
 {
 	SCRN_INFO_PTR(arg);
-	AMDGPUInfoPtr info = AMDGPUPTR(pScrn);
 
 	xf86DrvMsgVerb(pScrn->scrnIndex, X_INFO, AMDGPU_LOGLEVEL_DEBUG,
 		       "AMDGPUFreeScreen\n");
 
-	/* when server quits at PreInit, we don't need do this anymore */
-	if (!info)
-		return;
-
 	AMDGPUFreeRec(pScrn);
 }
 
-- 
2.6.2



More information about the xorg-driver-ati mailing list