patch-2.3.38 linux/drivers/video/fbcon.c

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

diff -u --recursive --new-file v2.3.37/linux/drivers/video/fbcon.c linux/drivers/video/fbcon.c
@@ -311,6 +311,10 @@
        fb_display[unit]._fontheightlog = fontheightlog;
        fb_display[unit].userfont = userfont;
        fb_display[unit].fb_info = newfb;
+       if (conp)
+	   conp->vc_display_fg = &newfb->display_fg;
+       if (!newfb->display_fg)
+	   newfb->display_fg = conp;
        if (!newfb->changevar)
            newfb->changevar = oldfb->changevar;
        /* tell console var has changed */
@@ -1167,8 +1171,12 @@
 
 static inline void fbcon_softback_note(struct vc_data *conp, int t, int count)
 {
-    unsigned short *p = (unsigned short *)
-    	(conp->vc_origin + t * conp->vc_size_row);
+    unsigned short *p;
+
+    if (conp->vc_num != fg_console)
+	return;
+    p = (unsigned short *)(conp->vc_origin + t * conp->vc_size_row);
+
     while (count) {
     	scr_memcpyw((u16 *)softback_in, p, conp->vc_size_row);
     	count--;

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