]> xenbits.xensource.com Git - people/andrewcoop/seabios.git/commitdiff
vgabios: Only init BDA device details in init_bios_area()
authorKevin O'Connor <kevin@koconnor.net>
Thu, 23 Oct 2014 17:04:17 +0000 (13:04 -0400)
committerKevin O'Connor <kevin@koconnor.net>
Mon, 27 Oct 2014 15:03:12 +0000 (11:03 -0400)
Don't set the device details when changing modes, and don't set mode
details outside of mode setting.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
vgasrc/vgabios.c
vgasrc/vgainit.c

index 786c009e3af26ec3bbfe064653b8c5a324bced43..e17974ace0954e9f5640638120453532ebf34dfe 100644 (file)
@@ -319,15 +319,6 @@ vga_set_mode(int mode, int flags)
     SET_BDA(video_pagestart, 0x0000);
     SET_BDA(video_page, 0x00);
 
-    // FIXME We nearly have the good tables. to be reworked
-    SET_BDA(dcc_index, 0x08);   // 8 is VGA should be ok for now
-    SET_BDA(video_savetable
-            , SEGOFF(get_global_seg(), (u32)&video_save_pointer_table));
-
-    // FIXME
-    SET_BDA(video_msr, 0x00); // Unavailable on vanilla vga, but...
-    SET_BDA(video_pal, 0x00); // Unavailable on vanilla vga, but...
-
     // Set the ints 0x1F and 0x43
     SET_IVT(0x1f, SEGOFF(get_global_seg(), (u32)&vgafont8[128 * 8]));
 
index 9d6dd1eeb6adb1c6d736aa869b7edfac78cf6b08..758fea4ba7be76f77f9897b69e70bbc72543b510 100644 (file)
@@ -108,20 +108,17 @@ init_bios_area(void)
     // set 80x25 color (not clear from RBIL but usual)
     set_equipment_flags(0x30, 0x20);
 
-    // the default char height
-    SET_BDA(char_height, 0x10);
-
-    // Clear the screen
-    SET_BDA(video_ctl, 0x60);
-
-    // Set the basic screen we have
-    SET_BDA(video_switches, 0xf9);
-
     // Set the basic modeset options
     SET_BDA(modeset_ctl, 0x51);
 
-    // Set the  default MSR
-    SET_BDA(video_msr, 0x09);
+    // FIXME We nearly have the good tables. to be reworked
+    SET_BDA(dcc_index, 0x08);   // 8 is VGA should be ok for now
+    SET_BDA(video_savetable
+            , SEGOFF(get_global_seg(), (u32)&video_save_pointer_table));
+
+    // FIXME
+    SET_BDA(video_msr, 0x00); // Unavailable on vanilla vga, but...
+    SET_BDA(video_pal, 0x00); // Unavailable on vanilla vga, but...
 }
 
 int VgaBDF VAR16 = -1;