Don't register a window private if VRR is disabled

It's not used in that case.

Reviewed-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
This commit is contained in:
Michel Dänzer
2019-02-12 18:12:23 +01:00
committed by Michel Dänzer
parent 5f91be77e0
commit 2a3d00dc7e

View File

@@ -365,7 +365,8 @@ static Bool AMDGPUCreateScreenResources_KMS(ScreenPtr pScreen)
}
}
if (!dixRegisterPrivateKey(&amdgpu_window_private_key,
if (info->vrr_support &&
!dixRegisterPrivateKey(&amdgpu_window_private_key,
PRIVATE_WINDOW,
sizeof(struct amdgpu_window_priv)))
return FALSE;