From d3fd7b40dbba842df4e540b303f9dcc647671437 Mon Sep 17 00:00:00 2001 From: David du Colombier <0intro@gmail.com> Date: Thu, 27 Jul 2000 00:00:00 +0000 Subject: [PATCH] Plan 9 from Bell Labs 2000-07-27 --- pc/ether2114x.c | 5 +++-- pc/vgamach64xx.c | 3 ++- port/devloopback.c | 7 ++++++- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/pc/ether2114x.c b/pc/ether2114x.c index 561fab85efdda01ac35406a72bf5014966287e00..90ad7b3f76b94d6f8cb22192b9554b0f5242028e 100644 --- a/pc/ether2114x.c +++ b/pc/ether2114x.c @@ -19,7 +19,7 @@ #include "etherif.h" -#define DEBUG (1) +#define DEBUG (0) #define debug if(DEBUG)print enum { @@ -1400,8 +1400,9 @@ dec2114xpci(void) softreset(ctlr); if(srom(ctlr)){ + iofree(ctlr->port); free(ctlr); - break; + continue; } switch(ctlr->id){ diff --git a/pc/vgamach64xx.c b/pc/vgamach64xx.c index 6adcc8f2feb6ee75bfb8f81496d61a65d5da2a75..9bf5437f1cf3a91a106f04f6232d8633e9bd4401 100644 --- a/pc/vgamach64xx.c +++ b/pc/vgamach64xx.c @@ -13,7 +13,7 @@ #include "screen.h" /* - * ATI Mach64(CT|ET|G*|VT|VU|L*). + * ATI Mach64(CT|ET|G*|V*|L*). */ static ushort mach64xxdid[] = { ('C'<<8)|'T', @@ -29,6 +29,7 @@ static ushort mach64xxdid[] = { ('G'<<8)|'Z', ('V'<<8)|'T', ('V'<<8)|'U', + ('V'<<8)|'V', ('L'<<8)|'B', ('L'<<8)|'I', ('L'<<8)|'M', diff --git a/port/devloopback.c b/port/devloopback.c index 0e564a1584bc012fb81dcc557e2bbe953707ddf8..1335b1cc60e392485b36e0efa3d85c9c152a5161 100644 --- a/port/devloopback.c +++ b/port/devloopback.c @@ -296,8 +296,13 @@ loopbackopen(Chan *c, int omode) lb = c->aux; qlock(lb); - if(TYPE(c->qid.path) == Qdata) + if(TYPE(c->qid.path) == Qdata){ + if(lb->link[ID(c->qid.path)].ref){ + qunlock(lb); + error(Einuse); + } lb->link[ID(c->qid.path)].ref++; + } qunlock(lb); c->mode = openmode(omode);