Browse Source

Plan 9 from Bell Labs 2007-10-08

David du Colombier 13 years ago
parent
commit
1a07f0f33a

+ 3 - 2
dist/replica/_plan9.db

@@ -7867,7 +7867,7 @@ sys/man/8/update - 664 sys sys 961259288 2336
 sys/man/8/venti - 664 sys sys 1190504986 12190
 sys/man/8/venti-backup - 664 sys sys 1188620038 2102
 sys/man/8/venti-fmt - 664 sys sys 1188620038 8626
-sys/man/8/vga - 664 sys sys 1141660952 3856
+sys/man/8/vga - 664 sys sys 1191737663 4129
 sys/man/fonts - 664 sys sys 944959700 218
 sys/man/index.html - 664 sys sys 1019918444 1859
 sys/man/mkfile - 664 sys sys 1018974173 2264
@@ -9841,7 +9841,7 @@ sys/src/cmd/aux/vga/io.c - 664 sys sys 1131110425 6329
 sys/src/cmd/aux/vga/mach32.c - 664 sys sys 1014925009 6004
 sys/src/cmd/aux/vga/mach64.c - 664 sys sys 1014925009 8279
 sys/src/cmd/aux/vga/mach64xx.c - 664 sys sys 1097900455 30266
-sys/src/cmd/aux/vga/main.c - 664 sys sys 1158594481 9765
+sys/src/cmd/aux/vga/main.c - 664 sys sys 1191737144 9892
 sys/src/cmd/aux/vga/mga2164w.c - 664 sys sys 1135487945 13173
 sys/src/cmd/aux/vga/mga4xx.c - 664 sys sys 1158594482 36898
 sys/src/cmd/aux/vga/mkfile - 664 sys sys 1115734903 927
@@ -15732,3 +15732,4 @@ usr/glenda/lib/profile - 664 glenda glenda 1105128663 890
 usr/glenda/readme.acme - 664 glenda glenda 1019860628 4753
 usr/glenda/readme.rio - 664 glenda glenda 1019860628 6370
 usr/glenda/tmp - 20000000775 glenda glenda 1018802620 0
+sys/src/cmd/upas/ned/nedmail.c - 664 sys sys 1191814356 44531

+ 3 - 3
dist/replica/plan9.db

@@ -7867,7 +7867,7 @@ sys/man/8/update - 664 sys sys 961259288 2336
 sys/man/8/venti - 664 sys sys 1190504986 12190
 sys/man/8/venti-backup - 664 sys sys 1188620038 2102
 sys/man/8/venti-fmt - 664 sys sys 1188620038 8626
-sys/man/8/vga - 664 sys sys 1141660952 3856
+sys/man/8/vga - 664 sys sys 1191737663 4129
 sys/man/fonts - 664 sys sys 944959700 218
 sys/man/index.html - 664 sys sys 1019918444 1859
 sys/man/mkfile - 664 sys sys 1018974173 2264
@@ -9841,7 +9841,7 @@ sys/src/cmd/aux/vga/io.c - 664 sys sys 1131110425 6329
 sys/src/cmd/aux/vga/mach32.c - 664 sys sys 1014925009 6004
 sys/src/cmd/aux/vga/mach64.c - 664 sys sys 1014925009 8279
 sys/src/cmd/aux/vga/mach64xx.c - 664 sys sys 1097900455 30266
-sys/src/cmd/aux/vga/main.c - 664 sys sys 1158594481 9765
+sys/src/cmd/aux/vga/main.c - 664 sys sys 1191737144 9892
 sys/src/cmd/aux/vga/mga2164w.c - 664 sys sys 1135487945 13173
 sys/src/cmd/aux/vga/mga4xx.c - 664 sys sys 1158594482 36898
 sys/src/cmd/aux/vga/mkfile - 664 sys sys 1115734903 927
@@ -14180,7 +14180,7 @@ sys/src/cmd/upas/ml/mlmgr.c - 664 sys sys 1045505888 2332
 sys/src/cmd/upas/ml/mlowner.c - 664 sys sys 1177589086 1143
 sys/src/cmd/upas/ned - 20000000775 sys sys 1062073146 0
 sys/src/cmd/upas/ned/mkfile - 664 sys sys 1060041738 233
-sys/src/cmd/upas/ned/nedmail.c - 664 sys sys 1143759341 44533
+sys/src/cmd/upas/ned/nedmail.c - 664 sys sys 1191814356 44531
 sys/src/cmd/upas/pop3 - 20000000775 sys sys 1064589604 0
 sys/src/cmd/upas/pop3/mkfile - 664 sys sys 1064589604 186
 sys/src/cmd/upas/pop3/pop3.c - 664 sys sys 1115039848 14327

+ 3 - 0
dist/replica/plan9.log

@@ -53033,3 +53033,6 @@
 1191623405 1 c cron/upas/cron - 664 upas sys 1191622540 284
 1191690003 0 c sys/games/lib/fortunes - 664 sys sys 1191689955 267133
 1191704405 0 c sys/games/lib/fortunes - 664 sys sys 1191703593 267174
+1191736807 0 c sys/src/cmd/aux/vga/main.c - 664 sys sys 1191737144 9892
+1191738605 0 c sys/man/8/vga - 664 sys sys 1191737663 4129
+1191814205 0 c sys/src/cmd/upas/ned/nedmail.c - 664 sys sys 1191814356 44531

+ 13 - 1
sys/man/8/vga

@@ -92,7 +92,7 @@ print a trace of the functions called.
 .B -V
 print a verbose trace of the functions called.
 .TP
-.B -x " file"
+.BI -x " file"
 use 
 .I file
 as the VGA database rather than
@@ -137,6 +137,10 @@ Using the monitor name
 instructs
 .I vga
 to use VESA BIOS calls to configure the display.
+Also, if our VGA controller can't be found in
+.IR vgadb ,
+.I vga
+will try the VESA calls.
 There are no entries for the
 .B vesa
 monitor in 
@@ -211,3 +215,11 @@ new VGA controller or monitor setting.
 It is useful in such cases to have
 the above command for setting the controller to a known state
 at your fingertips.
+.PP
+Due to the current implementation of access to the PC's
+`real mode',
+the VESA BIOS calls will only work on
+uniprocessors or on multiprocessors with
+.B *nomp=1
+in
+.IR plan9.ini .

+ 15 - 12
sys/src/cmd/aux/vga/main.c

@@ -251,19 +251,22 @@ main(int argc, char** argv)
 
 	/*
 	 * Try to identify the VGA card and grab
-	 * registers. Print them out if requested.
+	 * registers.  Print them out if requested.
+	 * If monitor=vesa or our vga controller can't be found
+	 * in vgadb, try vesa modes; failing that, try vga.
 	 */
-	if(strcmp(type, "vesa") == 0
-		|| dbctlr(dbname, vga) == 0 || vga->ctlr == 0)
-	if(dbvesa(vga) == 0 || vga->ctlr == 0){
-		Bprint(&stdout, "%s: controller not in %s, not vesa\n", argv0, dbname);
-		dumpbios(256);
-		type = "vga";
-		vsize = psize = "640x480x1";
-		virtual = 0;
-		vga->ctlr = &generic;
-		vga->link = &generic;
-	}
+	if(strcmp(type, "vesa") == 0 || dbctlr(dbname, vga) == 0 ||
+	    vga->ctlr == 0)
+		if(dbvesa(vga) == 0 || vga->ctlr == 0){
+			Bprint(&stdout, "%s: controller not in %s, not vesa\n",
+				argv0, dbname);
+			dumpbios(256);
+			type = "vga";
+			vsize = psize = "640x480x1";
+			virtual = 0;
+			vga->ctlr = &generic;
+			vga->link = &generic;
+		}
 
 	trace("main->snarf\n");
 	for(ctlr = vga->link; ctlr; ctlr = ctlr->link){

+ 2 - 2
sys/src/cmd/upas/ned/nedmail.c

@@ -1308,7 +1308,7 @@ printpart(String *s, char *part)
 	fd = open(s_to_c(path), OREAD);
 	s_free(path);
 	if(fd < 0){
-		fprint(2, "!message dissappeared\n");
+		fprint(2, "!message disappeared\n");
 		return 0;
 	}
 	tot = 0;
@@ -1453,7 +1453,7 @@ printpartindented(String *s, char *part, char *indent)
 	b = Bopen(s_to_c(path), OREAD);
 	s_free(path);
 	if(b == nil){
-		fprint(2, "!message dissappeared\n");
+		fprint(2, "!message disappeared\n");
 		return;
 	}
 	while((p = Brdline(b, '\n')) != nil){