From owner-freebsd-hackers Thu Sep 16 16:16:44 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from alpo.whistle.com (alpo.whistle.com [207.76.204.38]) by hub.freebsd.org (Postfix) with ESMTP id 239E314FBC for ; Thu, 16 Sep 1999 16:16:34 -0700 (PDT) (envelope-from julian@whistle.com) Received: from current1.whistle.com (current1.whistle.com [207.76.205.22]) by alpo.whistle.com (8.9.1a/8.9.1) with SMTP id QAA23938; Thu, 16 Sep 1999 16:16:32 -0700 (PDT) Date: Thu, 16 Sep 1999 16:16:32 -0700 (PDT) From: Julian Elischer To: Nick Hibma Cc: FreeBSD Hackers mailing list Subject: Re: nuking a vnode In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Thu, 16 Sep 1999, Julian Elischer wrote: > > On Thu, 16 Sep 1999, Nick Hibma wrote: > > > > > How do I nuke vnodes? This is the NetBSD code that needs to be emulated: > > > > /* locate the major number */ > > for (maj = 0; maj < nchrdev; maj++) > > if (cdevsw[maj].d_open == ulptopen) > > break; > > > > /* Nuke the vnodes for any open instances (calls close). */ > > mn = self->dv_unit; > > vdevgone(maj, mn, mn, VCHR); > > In -current something like: > > int major; > dev_t dev; > struct vnode *vp; > > major = ultp_cdevsw.d_maj; > dev = makedev(major, self->dv_unit) > vp = SLIST_FIRST(&dev->si_hlist); > if (vp) { > VOP_REVOKE(vp. REVOKEALL); ^ comma (,) > } > remove_dev(dev); > > 3.3 will be considerably different. > > > > > To Unsubscribe: send mail to majordomo@FreeBSD.org > with "unsubscribe freebsd-hackers" in the body of the message > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message