Date: Thu, 18 Mar 2004 22:35:07 +0800 (CST) From: "M. Warner Losh" <imp@bsdimp.com> To: guido@gvr.org Cc: new-bus@freebsd.org Subject: Re: ppbus probe problem Message-ID: <20040318.223507.19258520.imp@bsdimp.com> In-Reply-To: <20040318142637.GA92351@gvr.gvr.org> References: <200403181012.43455.dfr@nlsystems.com> <20040318.221110.109506333.imp@bsdimp.com> <20040318142637.GA92351@gvr.gvr.org>
next in thread | previous in thread | raw e-mail | index | archive | help
In message: <20040318142637.GA92351@gvr.gvr.org>
Guido van Rooij <guido@gvr.org> writes:
: On Thu, Mar 18, 2004 at 10:11:10PM +0800, M. Warner Losh wrote:
: > : > On Thu, Mar 18, 2004 at 09:13:33AM +0000, Doug Rabson wrote:
: > : > > I would use something like:
: > : > >
: > : > > static void
: > : > > vpo_identify(driver_t *driver, device_t parent)
: > : > > {
: > : > > device_t dev;
: > : > >
: > : > > dev = device_find_child(parent, "vpo", 0);
: > : > > if (!dev)
: > : > > BUS_ADD_CHILD(parent, 0, "vpo", -1);
: > : > > }
: > : >
: > : > So I'll update all of the ppbus drivers that way. Okay?
: > :
: > : I think so. Warner, do you have any objections?
: >
: > No.
: >
: > : In an ideal world, there should be some kind of BUS_UNIDENTIFY method
: > : which a driver could use to delete the devices it created in
: > : BUS_IDENTIFY.
: >
: > Or the bus would have a driver deleted routine that got called and it
: > would remove all instances of the devclass attached to it.
:
: Ok, I'll commit the changes Doug suggested.
:
: Warner: I have a working tw driver. Would you care looking at it?
: It is ppbus based.
I saw it, but didn't have a chance to look at it since I'm traveling
in Taiwan this week.
Warner
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040318.223507.19258520.imp>
