fix kernel types and acknowledge, if not fix, 386isms Reference: /n/atom/patch/applied/acidktype Date: Wed Feb 19 00:20:15 CET 2014 Signed-off-by: quanstro@quanstro.net --- /sys/lib/acid/kernel Wed Feb 19 00:20:10 2014 +++ /sys/lib/acid/kernel Wed Feb 19 00:20:11 2014 @@ -15,7 +15,7 @@ defn qid(qid) { complex Qid qid; - return itoa(qid.path\X)+"."+itoa(qid.vers\X); + return itoa(qid.path\Y)+"."+itoa(qid.vers\X); } defn path(p) { @@ -32,7 +32,7 @@ defn imagecacheline(h) { while h != 0 do { complex Image h; - print (h\X, " ", qid(h.qid), " type ", h.type\D, " ref ", h.ref, " next ", h.next\X, " ", path(h.c.path), "\n"); + print (h\W, " ", qid(h.qid), " type ", h.type\D, " ref ", h.ref, " next ", h.next\W, " ", path(h.c.path), "\n"); h = h.hash; } } @@ -53,10 +53,10 @@ c = (Chan)c; d=(Dev)(*(devtab+4*c.type)); q=c.qid; - print("chan(", c\X, "): ref=", c.ref\D, " #", d.dc\r, c.dev\D, " (", q.path, " ", q.vers\D, " ", q.type\X, ")"); + print("chan(", c\W, "): ref=", c.ref\D, " #", d.dc\r, c.dev\D, " (", q.path, " ", q.vers\D, " ", q.type\X, ")"); print(" fid=", c.fid\D, " iounit=", c.iounit\D); if c.ref != 0 then { - print(" ", path(c.path), " mchan=", c.mchan\X); + print(" ", path(c.path), " mchan=", c.mchan\W); if c.mchan != 0 then { print(" ", path(c.mchan.path)); } @@ -154,7 +154,7 @@ } } if bad != "" then - print("chan(", c\X, "):", bad, "\n"); + print("chan(", c\W, "):", bad, "\n"); } c = (Chan)c.link; } @@ -176,7 +176,7 @@ } else { s = *(s\s); } - print(p\X, " ", p.pid, ": ", *(p.text\s), " ", *(p.user\s), " pc ", p.pc\X, " ", s, " (", *(statename[p.state]\s), ") ut ", p.time[0]\D, " st ", p.time[1]\D, " qpc ", p.qpc\X, "\n"); + print(p\W, " ", p.pid, ": ", *(p.text\s), " ", *(p.user\s), " pc ", p.pc\W, " ", s, " (", *(statename[p.state]\s), ") ut ", p.time[0]\D, " st ", p.time[1]\D, " qpc ", p.qpc\W, "\n"); } } @@ -292,7 +292,7 @@ complex Segment s; if s != 0 then { - print(s\X, " ", segtypes[s.type&SG_TYPE], " ", s.base\X, "-", s.top\X, " image ", s.image\X, "\n"); + print(s\W, " ", segtypes[s.type&SG_TYPE], " ", s.base\W, "-", s.top\W, " image ", s.image\W, "\n"); } } @@ -315,7 +315,7 @@ return r; } -// find an address in a given segment +// find an address in a given segment (386 only) defn segaddr(s, a) { complex Segment s; local pte, pg; @@ -348,7 +348,7 @@ return main - (main & 0x0FFFFFFF); } -// PC only +// 386 only PTEMAPMEM = (1024*1024); BY2PG = 4096; PTEPERTAB = (PTEMAPMEM/BY2PG);