patch-2.2.13 linux/drivers/video/bwtwofb.c

Next file: linux/drivers/video/cgfourteenfb.c
Previous file: linux/drivers/video/atyfb.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.2.12/linux/drivers/video/bwtwofb.c linux/drivers/video/bwtwofb.c
@@ -1,4 +1,4 @@
-/* $Id: bwtwofb.c,v 1.7 1999/01/26 10:55:02 jj Exp $
+/* $Id: bwtwofb.c,v 1.7.2.1 1999/08/26 05:21:13 shadow Exp $
  * bwtwofb.c: BWtwo frame buffer driver
  *
  * Copyright (C) 1998 Jakub Jelinek   (jj@ultra.linux.cz)
@@ -85,12 +85,20 @@
 
 static void bw2_blank (struct fb_info_sbusfb *fb)
 {
+	unsigned long flags;
+
+	spin_lock_irqsave(&fb->lock, flags);
 	fb->s.bw2.regs->control &= ~BWTWO_CTL_ENABLE_VIDEO;
+	spin_unlock_irqrestore(&fb->lock, flags);
 }
 
 static void bw2_unblank (struct fb_info_sbusfb *fb)
 {
+	unsigned long flags;
+
+	spin_lock_irqsave(&fb->lock, flags);
 	fb->s.bw2.regs->control |= BWTWO_CTL_ENABLE_VIDEO;
+	spin_unlock_irqrestore(&fb->lock, flags);
 }
 
 static void bw2_margins (struct fb_info_sbusfb *fb, struct display *p, int x_margin, int y_margin)
@@ -216,7 +224,7 @@
 #endif
 	fb->margins = bw2_margins;
 	
-	fb->physbase = phys;
+	fb->physbase = __get_phys(fb->sbdp->sbus_vaddrs[0]);
 	fb->mmap_map = bw2_mmap_map;
 
 #ifdef __sparc_v9__

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)