Skip to contentSkip to conversation

radeonfb: don't blow up VGA console on load

PATCH New Benjamin Herrenschmidt 1 participant 1 message Jun 10, 2005 Framebuffer layer

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 radeonfb: don't blow up VGA console on load

Hi !

Current radeonfb memset's the framebuffer to 0 when loaded. This removes occasional artifacts but has the nasty side effect that if you load radeonfb without framebuffer console, you destroy the VGA text buffer, font, etc... radeon must not touch the framebuffer content when it doesn't "own" it.

drivers/video/aty/radeon_base.c +3 -4
Index: linux-work/drivers/video/aty/radeon_base.c
===================================================================
@@ -2374,10 +2374,9 @@
 	} while (   rinfo->fb_base == 0 &&
 		  ((rinfo->mapped_vram /=2) >= MIN_MAPPED_VRAM) );
 
-	if (rinfo->fb_base)
-		memset_io(rinfo->fb_base, 0, rinfo->mapped_vram);
-	else {
-		printk (KERN_ERR "radeonfb (%s): cannot map FB\n", pci_name(rinfo->pdev));
+	if (rinfo->fb_base == NULL) {
+		printk (KERN_ERR "radeonfb (%s): cannot map FB\n",
+			pci_name(rinfo->pdev));
 		ret = -EIO;
 		goto err_unmap_rom;
 	}

-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games. How far can you shotput a projector? How fast can you ride your desk chair down the office luge track? If you want to score the big prize, get to know the little guy. Play to win an NEC 61" plasma display: http://www.necitguy.com/?r=20