From owner-freebsd-net Wed Nov 6 12:58:26 2002 Delivered-To: freebsd-net@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 737AF37B401; Wed, 6 Nov 2002 12:58:25 -0800 (PST) Received: from InterJet.elischer.org (12-232-206-8.client.attbi.com [12.232.206.8]) by mx1.FreeBSD.org (Postfix) with ESMTP id 20D4843E91; Wed, 6 Nov 2002 12:58:24 -0800 (PST) (envelope-from julian@elischer.org) Received: from localhost (localhost.elischer.org [127.0.0.1]) by InterJet.elischer.org (8.9.1a/8.9.1) with ESMTP id MAA00741; Wed, 6 Nov 2002 12:48:08 -0800 (PST) Date: Wed, 6 Nov 2002 12:48:07 -0800 (PST) From: Julian Elischer To: "M. Warner Losh" Cc: myevmenk@exodus.net, current@FreeBSD.ORG, net@FreeBSD.ORG Subject: Re: Netgraph and KQUEUE(2) In-Reply-To: <20021106.125555.20031393.imp@bsdimp.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-net@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Wed, 6 Nov 2002, M. Warner Losh wrote: > In message: > Julian Elischer writes: > : > : > : On Wed, 6 Nov 2002, M. Warner Losh wrote: > : > : > : 1) Device driver in Netgraph node. When hardware is > : > : activated new Netgraph node is created and new > : > : kevent sent. devd (or something like devd) listens > : > : for these events and does something (loads firmware, > : > : activates device, etc.) > : > > : > Device drivers are not netgraph nodes. They will have a device_t > : > associated with them, which already sends a message via /dev/devctl to > : > devd. You can do anything you want with the results. There's no need > : > to reinvent the wheel that I'm almost done inventing. There's > : > absolutely no need to bring netgraph into it all, and doing so makes > : > it a less generic implementation. > : > : devices that are netgraph nodes may not have any entry in /dev > : and might only appear in the netgraph namespace.. > : e.g. if_ar.c if_sr.c > > It doesn't matter. *ALL* devices have device_t entries. Recall that > device_t is not dev_t. dev_t appears in /dev/. Hardware devices have > to attach to some bus. That's why devd is done in newbus land rather > than in dev_t land. Ok but there cound be netgraph nodes that have no hardware but could be called into creation by some external event. e.g. a netgraph hook on a pseudointerface like gif or tun. (not at present but a possibility I was looking at last week) > > Warner > To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-net" in the body of the message