Subject: Working 80x50 patch (was Re: wscons fonts)
To: Masao Uebayashi <uebayasi@soum.co.jp>
From: Bang Jun-Young <bjy@mogua.org>
List: port-i386
Date: 12/12/2000 21:54:46
Well, I managed to make wscons do 80x50 mode. Here is the patch against
1.5 source:

--- /usr/src/sys/dev/ic/vga_subr.c	Tue Jan 25 02:44:03 2000
+++ vga_subr.c	Tue Dec 12 21:17:37 2000
@@ -94,12 +94,20 @@
 {
 	int offset, i, j, s;
 
+#if 0
 	/* fontset number swizzle done in vga_setfontset() */
 	offset = (fontset << 13) | (first << 5);
+#else
+	offset = 0;
+#endif
 
 	s = splhigh();
 	fontram(vh);
 
+	for (i = 0; i < 8192; i++)
+		bus_space_write_1(vh->vh_memt, vh->vh_allmemh,
+				  offset + i, 0);
+	
 	for (i = 0; i < num; i++)
 		for (j = 0; j < lpc; j++)
 			bus_space_write_1(vh->vh_memt, vh->vh_allmemh,

Once you apply it to the kernel source tree and rebuild it, you'll be 
able to use 80x50 mode with additional vcons (there're some known caveats, 
though). Don't forget to include an appropriate font line to 
/etc/wscons.conf. 

It seems that my ATI 3D Rage doesn't allow charmap select register to 
change in some case. As a result, it could access only a font in slot 0. 
 
A better solution would be to swap out the font currently in use to memory 
and load a new one into slot 0 before the console is switched to a 
different mode. 

Jun-Young

--
Bang Jun-Young <bjy@mogua.org>