Move realmode into link section. Add Matrox mmio segment. [rsc] --rw-rw-r-- M 55859 glenda sys 1447 Nov 18 11:59 sys/src/9/pc/pcdisk /n/sourcesdump/2005/1118/plan9/sys/src/9/pc/pcdisk:33,38 - /n/sourcesdump/2005/1119/plan9/sys/src/9/pc/pcdisk:33,39 usb link + realmode devpccard devi82365 apm apmjump /n/sourcesdump/2005/1118/plan9/sys/src/9/pc/pcdisk:60,66 - /n/sourcesdump/2005/1119/plan9/sys/src/9/pc/pcdisk:61,66 usbuhci misc - realmode archmp mp apic sdata pci sdscsi [rsc] --rw-rw-r-- M 55859 glenda sys 4769 Nov 18 11:27 sys/src/9/pc/vgamga2164w.c /n/sourcesdump/2005/1118/plan9/sys/src/9/pc/vgamga2164w.c:58,68 - /n/sourcesdump/2005/1119/plan9/sys/src/9/pc/vgamga2164w.c:58,70 scr->mmio = vmap(p->mem[0].bar&~0x0F, p->mem[0].size); if(scr->mmio == nil) return; + addvgaseg("mga2164wmmio", p->mem[0].bar&~0x0F, p->mem[0].size); vgalinearaddr(scr, p->mem[1].bar&~0x0F, 8*MB); }else{ scr->mmio = vmap(p->mem[1].bar&~0x0F, p->mem[1].size); if(scr->mmio == nil) return; + addvgaseg("mga2164wmmio", p->mem[1].bar&~0x0F, p->mem[1].size); vgalinearaddr(scr, p->mem[0].bar&~0x0F, 16*MB); } if(scr->paddr) [rsc] --rw-rw-r-- M 55859 glenda sys 1428 Nov 18 11:59 sys/src/9/pc/pc /n/sourcesdump/2005/1118/plan9/sys/src/9/pc/pc:36,44 - /n/sourcesdump/2005/1119/plan9/sys/src/9/pc/pc:36,44 tv link + realmode devpccard devi82365 - realmode ether2000 ether8390 ether2114x pci ether589 etherelnk3 [rsc] --rw-rw-r-- M 55859 glenda sys 1447 Nov 18 11:59 sys/src/9/pc/pcdisk [rsc] --rw-rw-r-- M 55859 glenda sys 23864 Nov 18 14:17 sys/src/9/pc/mmu.c /n/sourcesdump/2005/1118/plan9/sys/src/9/pc/mmu.c:393,404 - /n/sourcesdump/2005/1119/plan9/sys/src/9/pc/mmu.c:393,405 void putmmu(ulong va, ulong pa, Page*) { - int old; + int old, s; Page *page; if(up->mmupdb == nil) upallocpdb(); + s = splhi(); if(!(vpd[PDX(va)]&PTEVALID)){ if(up->mmufree == 0) page = newpage(0, 0, 0); /n/sourcesdump/2005/1118/plan9/sys/src/9/pc/mmu.c:417,422 - /n/sourcesdump/2005/1119/plan9/sys/src/9/pc/mmu.c:418,424 vpt[VPTX(va)] = pa|PTEUSER|PTEVALID; if(old&PTEVALID) flushpg(va); + splx(s); } /* /n/sourcesdump/2005/1118/plan9/sys/src/9/pc/mmu.c:896,902 - /n/sourcesdump/2005/1119/plan9/sys/src/9/pc/mmu.c:898,904 va = (ulong)v; if(va < KZERO) - panic("paddr: va=%#.8lux", va); + panic("paddr: va=%#.8lux pc=%#.8lux", va, getcallerpc(&va)); return va-KZERO; } /n/sourcesdump/2005/1118/plan9/sys/src/9/pc/mmu.c:989,991 - /n/sourcesdump/2005/1119/plan9/sys/src/9/pc/mmu.c:991,1036 if(!print) iprint("%d pages in mach pdbpools\n", n); } + + void + checkfault(ulong addr, ulong pc) + { + ulong *a; + int i; + + print("user fault: addr=%.8lux pc=%.8lux\n", addr, pc); + if(!(vpd[PDX(addr)]&PTEVALID)) + print("addr not mapped (vpd=%.8lux)\n", vpd[PDX(addr)]); + else if(!(vpt[VPTX(addr)]&PTEVALID)) + print("addr not mapped (vpd=%.8lux vpt=%.8lux)\n", + vpd[PDX(addr)], vpt[VPTX(addr)]); + else + print("addr mapped (vpd=%.8lux vpt=%.8lux)\n", + vpd[PDX(addr)], vpt[VPTX(addr)]); + + if(!(vpd[PDX(pc)]&PTEVALID)) + print("pc not mapped (vpd=%.8lux)\n", vpd[PDX(pc)]); + else if(!(vpt[VPTX(pc)]&PTEVALID)) + print("pc not mapped (vpd=%.8lux vpt=%.8lux)\n", + vpd[PDX(pc)], vpt[VPTX(pc)]); + else{ + print("pc mapped (vpd=%.8lux vpt=%.8lux)\n", + vpd[PDX(pc)], vpt[VPTX(pc)]); + if(PPN(pc) == PPN(pc+4)) /* not crossing into an unmapped page */ + print("*pc: %.8lux\n", *(ulong*)pc); + a = (ulong*)PPN(pc); + for(i=0; ipc); sprint(buf, "sys: trap: fault %s addr=0x%lux", read ? "read" : "write", addr); postnote(up, 1, buf, NDebug); Write regular expression errors to log. [rsc] --rw-rw-r-- M 55859 glenda sys 6386 Nov 18 11:26 sys/src/cmd/upas/send/rewrite.c /n/sourcesdump/2005/1118/plan9/sys/src/cmd/upas/send/rewrite.c:282,287 - /n/sourcesdump/2005/1119/plan9/sys/src/cmd/upas/send/rewrite.c:282,289 regerror(char* s) { fprint(2, "rewrite: %s\n", s); + /* make sure the message is seen locally */ + syslog(0, "mail", "error in rewrite: %s", s); } extern void [rsc] --rw-rw-r-- M 55859 glenda sys 31097 Nov 18 11:26 sys/src/cmd/upas/smtp/smtpd.c /n/sourcesdump/2005/1118/plan9/sys/src/cmd/upas/smtp/smtpd.c:157,163 - /n/sourcesdump/2005/1119/plan9/sys/src/cmd/upas/smtp/smtpd.c:157,163 if(debug){ close(2); - snprint(buf, sizeof(buf), "%s/smtpd", UPASLOG); + snprint(buf, sizeof(buf), "%s/smtpd.db", UPASLOG); if (open(buf, OWRITE) >= 0) { seek(2, 0, 2); fprint(2, "%d smtpd %s\n", getpid(), thedate()); /n/sourcesdump/2005/1118/plan9/sys/src/cmd/upas/smtp/smtpd.c:1221,1226 - /n/sourcesdump/2005/1119/plan9/sys/src/cmd/upas/smtp/smtpd.c:1221,1236 } reply("%d mail process terminated abnormally\r\n", code); } else { + /* + * if a message appeared on stderr, despite good status, + * log it. this can happen if rewrite.in contains a bad + * r.e., for example. + */ + if(*s_to_c(err)) + syslog(0, "smtpd", + "%s returned good status, but said: %s", + s_to_c(mailer), s_to_c(err)); + if(filterstate == BLOCKED) reply("554 we believe this is spam. we don't accept it.\r\n"); else - [rsc] --rw-rw-r-- M 55859 glenda sys 6695 Nov 18 12:56 sys/src/lib9p/file.c [rsc] --rw-rw-r-- M 55859 glenda sys 6695 Nov 18 12:56 sys/src/lib9p/file.c Add malloc tags. [rsc] --rw-rw-r-- M 55859 glenda sys 589 Nov 18 11:32 sys/src/libc/9sys/getenv.c /n/sourcesdump/2005/1118/plan9/sys/src/libc/9sys/getenv.c:20,25 - /n/sourcesdump/2005/1119/plan9/sys/src/libc/9sys/getenv.c:20,26 s = seek(f, 0, 2); ans = malloc(s+1); if(ans) { + setmalloctag(ans, getcallerpc(&name)); seek(f, 0, 0); r = read(f, ans, s); if(r >= 0) { [rsc] --rw-rw-r-- M 55859 glenda sys 205 Nov 18 11:32 sys/src/libc/fmt/smprint.c /n/sourcesdump/2005/1118/plan9/sys/src/libc/fmt/smprint.c:10,14 - /n/sourcesdump/2005/1119/plan9/sys/src/libc/fmt/smprint.c:10,15 va_start(args, fmt); p = vsmprint(fmt, args); va_end(args); + setmalloctag(p, getcallerpc(&fmt)); return p; }