Date: Wed, 06 Oct 1999 20:41:37 -0600 From: Warner Losh <imp@village.org> To: Doug Rabson <dfr@nlsystems.com> Cc: new-bus@FreeBSD.ORG, dfr@FreeBSD.ORG Subject: Re: Question on loading buses Message-ID: <199910070241.UAA00348@harmony.village.org> In-Reply-To: Your message of "Thu, 07 Oct 1999 01:31:39 BST." <Pine.BSF.4.10.9910070129570.327-100000@salmon.nlsystems.com> References: <Pine.BSF.4.10.9910070129570.327-100000@salmon.nlsystems.com>
next in thread | previous in thread | raw e-mail | index | archive | help
In message <Pine.BSF.4.10.9910070129570.327-100000@salmon.nlsystems.com> Doug Rabson writes:
: The call should happen before the probe loop otherwise new devices created
: by the identify method won't be probed. Note that for the isa bus, we
: really need an isa_driver_added which can allocate pnp resources etc.
: after the identify creates them.
OK. For the moment I've not done the isa_driver_added since I don't
understand the pnp code. However, the following works. Can you
comment on it?
Warner
Index: kern/bus_if.m
===================================================================
RCS file: /home/imp/FreeBSD/CVS/src/sys/kern/bus_if.m,v
retrieving revision 1.14
diff -u -r1.14 bus_if.m
--- bus_if.m 1999/08/28 00:46:09 1.14
+++ bus_if.m 1999/10/07 02:19:10
@@ -113,7 +113,7 @@
METHOD void driver_added {
device_t dev;
driver_t *driver;
-}
+} DEFAULT bus_generic_driver_added;
#
# For busses which use use drivers supporting DEVICE_IDENTIFY to
Index: kern/subr_bus.c
===================================================================
RCS file: /home/imp/FreeBSD/CVS/src/sys/kern/subr_bus.c,v
retrieving revision 1.42
diff -u -r1.42 subr_bus.c
--- subr_bus.c 1999/09/10 21:11:23 1.42
+++ subr_bus.c 1999/10/07 02:34:05
@@ -1924,6 +1924,7 @@
{
device_t child;
+ DEVICE_IDENTIFY(driver, dev);
for (child = TAILQ_FIRST(&dev->children);
child; child = TAILQ_NEXT(child, link))
if (child->state == DS_NOTPRESENT)
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-new-bus" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199910070241.UAA00348>
