From owner-cvs-all Wed Oct 17 12:36:54 2001 Delivered-To: cvs-all@freebsd.org Received: from prism.flugsvamp.com (cb58709-a.mdsn1.wi.home.com [24.17.241.9]) by hub.freebsd.org (Postfix) with ESMTP id A57A737B405; Wed, 17 Oct 2001 12:36:48 -0700 (PDT) Received: (from jlemon@localhost) by prism.flugsvamp.com (8.11.0/8.11.0) id f9HJa5497019; Wed, 17 Oct 2001 14:36:05 -0500 (CDT) (envelope-from jlemon) Date: Wed, 17 Oct 2001 14:36:05 -0500 From: Jonathan Lemon To: Poul-Henning Kamp Cc: Jonathan Lemon , cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/kern kern_conf.c src/sys/sys conf.h Message-ID: <20011017143605.O75389@prism.flugsvamp.com> References: <200110171847.f9HIlCa70666@freefall.freebsd.org> <40829.1003346384@critter.freebsd.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 1.0pre2i In-Reply-To: <40829.1003346384@critter.freebsd.dk> Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, Oct 17, 2001 at 09:19:44PM +0200, Poul-Henning Kamp wrote: > In message <200110171847.f9HIlCa70666@freefall.freebsd.org>, Jonathan Lemon wri > tes: > >jlemon 2001/10/17 11:47:12 PDT > > > > Modified files: > > sys/kern kern_conf.c > > sys/sys conf.h > > Log: > > Add dev_named(dev, name), which is similar in spirit to devtoname(). > > This function returns success if the device is known by either 'name' > > or any of its aliases. > > Could you explain what you need this for ? Device aliases. E.g.: (/dev/net3 -> /dev/net/fxp0) Unfortunately, name lookups are currently done by passing the name into the kernel, and then comparing it to every entry in the ifnet list. So what I need to do is walk down the si_children list and look at their names as well. It would be cleaner if this parsing was done by devfs, and the device was referenced by a udev_t (or similar) but that would require changing the applications to perform the device open. -- Jonathan To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message