From cf30230c5c81a54346e729d3ccd6f2358034880a Mon Sep 17 00:00:00 2001 From: David du Colombier <0intro@gmail.com> Date: Sat, 4 May 1991 00:00:00 +0000 Subject: [PATCH] Plan 9 from Bell Labs 1991-05-04 --- port/devip.c | 2 +- port/portdat.h | 8 ++++++-- port/stip.c | 1 + port/stream.c | 1 + ss/faultsparc.c | 1 - ss/trap.c | 2 -- 6 files changed, 9 insertions(+), 6 deletions(-) diff --git a/port/devip.c b/port/devip.c index 266c4f5ff13c5509a8a127f5ab97fa16b90c4751..6922ae6b773b0e3fd3622fff22e0b5ff23d7b0a7 100644 --- a/port/devip.c +++ b/port/devip.c @@ -602,7 +602,7 @@ tcpstopen(Queue *q, Stream *s) Tcpoutput = WR(q); /* This never goes away - we use this queue to send acks/rejects */ s->opens++; - + s->inuse++; /* Flow control and tcp timer processes */ kproc("tcpack", tcpackproc, 0); kproc("tcpflow", tcpflow, &ipconv[s->dev]); diff --git a/port/portdat.h b/port/portdat.h index 444f4c0cc5d98f173d3004013760e4a12e0bc6b7..cce2e2c96f3631ff032ded7dbb36feda50786f7b 100644 --- a/port/portdat.h +++ b/port/portdat.h @@ -347,8 +347,12 @@ struct Proc int wokeup; /* whether sleep was interrupted */ ulong pc; /* DEBUG only */ int kp; /* true if a kernel process */ - union { - int pidonmach[MAXMACH]; /* !!Compatability with mips!! */ + /* + * MMU goo. which of the fillowing fields gets used depends on the + * processor. + */ + struct { + int pidonmach[MAXMACH]; MMU *mmu; int nmmuseg; /* number of segments active in mmu */ }; diff --git a/port/stip.c b/port/stip.c index 5c3939e6f5c6c3e749e079a97664367611f6e70e..0ac0553b9fe3b6af10cd8b8bf2854bdfcc01e277 100644 --- a/port/stip.c +++ b/port/stip.c @@ -73,6 +73,7 @@ ipetheropen(Queue *q, Stream *s) if(!Etherq) { Etherq = WR(q); s->opens++; /* Hold this queue in place */ + s->inuse++; } DPRINT("ipetheropen EQ %lux dev=%d id=%d RD %lux WR %lux\n", diff --git a/port/stream.c b/port/stream.c index 82e8bab858525b9783ef083801fdaff1220805d7..9320bac3ba6809b57f0a85af3f5816ecfb0d1514 100644 --- a/port/stream.c +++ b/port/stream.c @@ -808,6 +808,7 @@ streamnew(ushort type, ushort dev, ushort id, Qinfo *qi, int noopen) /* * hang a device and process q off the stream */ + s->forcedelim = 0; s->inuse = 1; if(noopen) s->opens = 0; diff --git a/ss/faultsparc.c b/ss/faultsparc.c index 1c9d679d23d3a5e35699e2a5710f584353273956..a2c2f5b932de6ef30dbe131e3166f0618362a20c 100644 --- a/ss/faultsparc.c +++ b/ss/faultsparc.c @@ -25,7 +25,6 @@ faultsparc(Ureg *ur) read = 0; } spllo(); -print("fault: %s pc=0x%lux addr %lux %d\n", excname(tbr), ur->pc, addr, read); /**/ if(u == 0){ dumpregs(ur); panic("fault u==0 pc=%lux addr=%lux", ur->pc, addr); diff --git a/ss/trap.c b/ss/trap.c index de013f5afc87dcde5620d64d825f12a89b23e791..525b5e76398780b7ea347016a67671d7e7405cc1 100644 --- a/ss/trap.c +++ b/ss/trap.c @@ -214,7 +214,6 @@ notify(Ureg *ur) unlock(&u->p->debug); return; } -print("suicide: %s\n", u->note[0].msg); if(u->note[0].flag!=NUser && (u->notified || u->notify==0)){ if(u->note[0].flag == NDebug) pprint("suicide: %s\n", u->note[0].msg); @@ -337,7 +336,6 @@ syscall(Ureg *aur) u->nerrlab = 0; ret = -1; -print("syscall %s %d %d\n", u->p->text, u->p->pid, r7); if(!waserror()){ if(r7 >= sizeof systab/BY2WD){ pprint("bad sys call number %d pc %lux\n", r7, ((Ureg*)UREGADDR)->pc);