From 6ef1ad6a46348d3aecd8d1f5e94431ca2298853c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michel=20D=C3=A4nzer?= Date: Fri, 13 Jul 2012 11:15:25 +0200 Subject: Deal more gracefully with DRI2 being unavailable at build or run time. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Michel Dänzer --- src/radeon_kms.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/radeon_kms.c') diff --git a/src/radeon_kms.c b/src/radeon_kms.c index 5cc362f9..a4f46d79 100644 --- a/src/radeon_kms.c +++ b/src/radeon_kms.c @@ -425,6 +425,10 @@ shadowfb: return TRUE; } +#ifdef DRI2 + info->dri2.available = !!xf86LoadSubModule(pScrn, "dri2"); +#endif + if (radeon_glamor_pre_init(pScrn)) return TRUE; @@ -740,6 +744,7 @@ Bool RADEONPreInit_KMS(ScrnInfoPtr pScrn, int flags) goto fail; } + info->dri2.available = FALSE; info->dri2.enabled = FALSE; info->dri2.pKernelDRMVersion = drmGetVersion(info->dri2.drm_fd); if (info->dri2.pKernelDRMVersion == NULL) { -- cgit v1.2.3