Module Name:    src
Committed By:   macallan
Date:           Thu Jan  5 21:40:03 UTC 2012

Modified Files:
        src/sys/dev/pci: radeonfb.c

Log Message:
turns out we can feed some radeons faster than they can process image uploads,
so make periodic stops to let the fifo drain a bit
now this works on my Blade 2500 with a 32MB XVR-100


To generate a diff of this commit:
cvs rdiff -u -r1.50 -r1.51 src/sys/dev/pci/radeonfb.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/pci/radeonfb.c
diff -u src/sys/dev/pci/radeonfb.c:1.50 src/sys/dev/pci/radeonfb.c:1.51
--- src/sys/dev/pci/radeonfb.c:1.50	Wed Jan  4 15:56:18 2012
+++ src/sys/dev/pci/radeonfb.c	Thu Jan  5 21:40:03 2012
@@ -1,4 +1,4 @@
-/*	$NetBSD: radeonfb.c,v 1.50 2012/01/04 15:56:18 macallan Exp $ */
+/*	$NetBSD: radeonfb.c,v 1.51 2012/01/05 21:40:03 macallan Exp $ */
 
 /*-
  * Copyright (c) 2006 Itronix Inc.
@@ -70,7 +70,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: radeonfb.c,v 1.50 2012/01/04 15:56:18 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: radeonfb.c,v 1.51 2012/01/05 21:40:03 macallan Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -2556,8 +2556,10 @@ radeonfb_putchar_aa32(void *cookie, int 
 	 * could process them, especially when doing the alpha blending stuff
 	 * along the way, so just make sure there's some room in the FIFO and
 	 * then hammer away
+	 * As it turns out we can, so make periodic stops to let the FIFO
+	 * drain.
 	 */
-	radeonfb_wait_fifo(sc, 10);
+	radeonfb_wait_fifo(sc, 20);
 	for (i = 0; i < ri->ri_fontscale; i++) {
 		aval = *data;
 		data++;
@@ -2573,6 +2575,8 @@ radeonfb_putchar_aa32(void *cookie, int 
 			        (g & 0xff00) |
 			        (b & 0xff00) >> 8;
 		}
+		if (i & 16)
+			radeonfb_wait_fifo(sc, 20);
 		PUT32(sc, RADEON_HOST_DATA0, pixel);
 	}
 }

Reply via email to