[PATCH] savage: Warn if broken drm maps are detected

Tormod Volden lists.tormod at gmail.com
Sun Sep 18 13:28:31 PDT 2011


From: Tormod Volden <debian.tormod at gmail.com>

Linux kernel 2.6.30 - 2.6.39 had broken drm maps which would result
in assorted problems. Leave a message in the log if it looks like
the framebuffer map and the aperture map are mixed up.

https://bugs.freedesktop.org/show_bug.cgi?id=32511

Signed-off-by: Tormod Volden <debian.tormod at gmail.com>

---
 src/savage_dri.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/src/savage_dri.c b/src/savage_dri.c
index 69563bd..8750925 100644
--- a/src/savage_dri.c
+++ b/src/savage_dri.c
@@ -1070,6 +1070,11 @@ Bool SAVAGEDRIScreenInit( ScreenPtr pScreen )
       return FALSE;
    }
 
+   /* Linux kernel DRM broken in 2.6.30 through 2.6.39 */
+   if (pDRIInfo->hFrameBuffer == pSAVAGEDRIServer->aperture.handle)
+       xf86DrvMsg( pScrn->scrnIndex, X_WARNING,
+		   "[drm] Detected broken drm maps. Please upgrade to linux kernel 3.x\n");
+
    if ( !SAVAGEDRIBuffersInit( pScreen ) ) {
       SAVAGEDRICloseScreen( pScreen );
       return FALSE;
-- 
1.7.5.4



More information about the xorg-devel mailing list