xf86-video-ati: Branch 'master'

Michel Dänzer daenzer at kemper.freedesktop.org
Thu May 3 06:19:33 PDT 2012


 src/radeon_exa_shared.c |   27 ++++++++++++++++++++++-----
 1 file changed, 22 insertions(+), 5 deletions(-)

New commits:
commit 6bda7ceda645e838723883d133d614def1511d16
Author: Michel Dänzer <michel.daenzer at amd.com>
Date:   Thu May 3 15:07:30 2012 +0200

    EXA: Attempt to fix solid picture acceleration with UMS.
    
    Only compile tested, but should fix
    https://bugs.freedesktop.org/show_bug.cgi?id=49182 .
    
    Signed-off-by: Michel Dänzer <michel.daenzer at amd.com>

diff --git a/src/radeon_exa_shared.c b/src/radeon_exa_shared.c
index 28dc335..31e2870 100644
--- a/src/radeon_exa_shared.c
+++ b/src/radeon_exa_shared.c
@@ -128,19 +128,36 @@ Bool RADEONCheckBPP(int bpp)
 
 PixmapPtr RADEONSolidPixmap(ScreenPtr pScreen, uint32_t solid)
 {
+    ScrnInfoPtr pScrn = xf86Screens[pScreen->myNum];
+    RADEONInfoPtr info = RADEONPTR(pScrn);
     PixmapPtr pPix = pScreen->CreatePixmap(pScreen, 1, 1, 32, 0);
-    struct radeon_bo *bo;
 
     exaMoveInPixmap(pPix);
-    bo = radeon_get_pixmap_bo(pPix);
 
-    if (radeon_bo_map(bo, 1)) {
+#if defined(XF86DRM_MODE)
+    if (info->cs) {
+	struct radeon_bo *bo;
+
+	bo = radeon_get_pixmap_bo(pPix);
+
+	if (radeon_bo_map(bo, 1)) {
+	    pScreen->DestroyPixmap(pPix);
+	    return NULL;
+	}
+
+	memcpy(bo->ptr, &solid, 4);
+	radeon_bo_unmap(bo);
+
+	return pPix;
+    }
+#endif
+
+    if (!exaDrawableIsOffscreen(&pPix->drawable)) {
 	pScreen->DestroyPixmap(pPix);
 	return NULL;
     }
 
-    memcpy(bo->ptr, &solid, 4);
-    radeon_bo_unmap(bo);
+    memcpy(info->FB + exaGetPixmapOffset(pPix), &solid, 4);
 
     return pPix;
 }


More information about the xorg-commit mailing list