From owner-freebsd-current Thu Nov 2 12:41:41 2000 Delivered-To: freebsd-current@freebsd.org Received: from palrel3.hp.com (palrel3.hp.com [156.153.255.226]) by hub.freebsd.org (Postfix) with ESMTP id 0FC6037B479; Thu, 2 Nov 2000 12:41:39 -0800 (PST) Received: from adlmail.cup.hp.com (adlmail.cup.hp.com [15.0.100.30]) by palrel3.hp.com (Postfix) with ESMTP id 28858A0D1; Thu, 2 Nov 2000 12:41:12 -0800 (PST) Received: from cup.hp.com (gauss.cup.hp.com [15.28.97.152]) by adlmail.cup.hp.com (8.9.3 (PHNE_18546)/8.9.3 SMKit7.02) with ESMTP id MAA10393; Thu, 2 Nov 2000 12:41:11 -0800 (PST) Message-ID: <3A01D167.DB687DDB@cup.hp.com> Date: Thu, 02 Nov 2000 15:41:11 -0500 From: Marcel Moolenaar Organization: Hewlett-Packard X-Mailer: Mozilla 4.73 [en] (X11; U; Linux 2.2.12 i386) X-Accept-Language: en MIME-Version: 1.0 To: John Baldwin Cc: freebsd-current@FreeBSD.org, andrea@webcom.it Subject: Re: WARNING: driver bpf should register devices with make_dev() References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG John Baldwin wrote: > > Quick question: Is this a problem for people _without_ DEVFS? That's a yes for me. > non-DEVFS case. Try this hackish patch: > > Index: bpf.c > =================================================================== > RCS file: /usr/cvs/src/sys/net/bpf.c,v > retrieving revision 1.68 > diff -u -r1.68 bpf.c > --- bpf.c 2000/10/09 14:19:09 1.68 > +++ bpf.c 2000/11/02 20:26:09 > @@ -363,7 +363,7 @@ > */ > if (d) > return (EBUSY); > - if (!dev->si_flags & SI_NAMED) > + if (!devfs_present) > make_dev(&bpf_cdevsw, minor(dev), UID_ROOT, GID_WHEEL, 0600, > "bpf%d", dev2unit(dev)); > MALLOC(d, struct bpf_d *, sizeof(*d), M_BPF, M_WAITOK); > > Hmm. Or try doing changing it to this instead: > > if (dev->si_flags & SI_NAMED != 0) > > It could be an order of operations buglet. Give me a couple of days to play with it... -- Marcel Moolenaar mail: marcel@cup.hp.com / marcel@FreeBSD.org tel: (408) 447-4222 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message