xserver: Branch 'master'

Søren Sandmann Pedersen sandmann at kemper.freedesktop.org
Tue Feb 6 23:51:07 EET 2007


 fb/fbpict.c |   21 ++++++++++++++++++++-
 1 files changed, 20 insertions(+), 1 deletion(-)

New commits:
diff-tree b2cd3b133748cc5aa541905a703a6fdb1cbbb1e6 (from 760a38c4c7ab66ae653d3acb92f5cda4bd44edd6)
Author: Soren Sandmann Pedersen <ssp at dhcp83-218.boston.redhat.com>
Date:   Tue Feb 6 16:43:37 2007 -0500

    Fix for AMD cpu detection. Bug 9614, Dan Williams.
    
    Credit for the fixes in this patch goes to:
    
    Marco Gritti <mpg at redhat dot com>
    Jordan Crouse <jordan dot crouse at amd dot com>

diff --git a/fb/fbpict.c b/fb/fbpict.c
index 28503c0..39d8d9f 100644
--- a/fb/fbpict.c
+++ b/fb/fbpict.c
@@ -189,6 +189,23 @@ fbCompositeSolidMask_nx8888x8888C (CARD8
     fbComposeGetStart (pDst, xDst, yDst, CARD32, dstStride, dstLine, 1);
     fbComposeGetStart (pMask, xMask, yMask, CARD32, maskStride, maskLine, 1);
 
+    {
+	comp_image_t src, msk, dst;
+	comp_pixel_t src_pixel;
+	comp_format_t msk_format = { 0xff000000, 0x00ff0000, 0x0000ff00, 0x000000ff };
+	
+	src_pixel.red   = src & 0x000000ff;
+	src_pixel.green = src & 0x0000ff00;
+	src_pixel.blue  = src & 0x00ff0000;
+	src_pixel.alpha = src & 0xff000000;
+	
+	comp_image_init_solid (&src, &src_pixel);
+	comp_image_init_bits  (&msk, maskLine, maskStride, &msk_format);
+	comp_image_init_bits  (&dst, dstLine, dstStride, &dst_format);
+
+	comp_over_c (src, msk, dst, srcX, srcY, mskX, mskY, dstX, dstY);
+    }
+    
     while (height--)
     {
 	dst = dstLine;
@@ -1516,7 +1533,9 @@ static unsigned int detectCPUFeatures(vo
             features |= SSE;
         if (result & (1 << 26))
             features |= SSE2;
-        if ((result & MMX) && !(result & SSE) && (strcmp(vendor, "AuthenticAMD") == 0)) {
+        if ((features & MMX) && !(features & SSE) &&
+            (strcmp(vendor, "AuthenticAMD") == 0 ||
+             strcmp(vendor, "Geode by NSC") == 0)) {
             /* check for AMD MMX extensions */
 
             unsigned int result;            



More information about the xorg-commit mailing list