sys/kern/subr_bus.c
/**
 * @brief Helper function for implementing BUS_DRIVER_ADDED().
 *
 * This implementation of BUS_DRIVER_ADDED() simply calls the driver's
 * DEVICE_IDENTIFY() method to allow it to add new children to the bus
 * and then calls device_probe_and_attach() for each unattached child.
 */
@brief Helper function for implementing BUS_DRIVER_ADDED().
This implementation of BUS_DRIVER_ADDED() simply calls the driver's
DEVICE_IDENTIFY() method to allow it to add new children to the bus
and then calls device_probe_and_attach() for each unattached child.
@brief Helper function for implementing BUS_DRIVER_ADDED () . This implementation of BUS_DRIVER_ADDED () simply calls the driver ' s DEVICE_IDENTIFY () method to allow it to add new children to the bus and then calls device_probe_and_attach () for each unattached child .
void
bus_generic_driver_added(device_t dev, driver_t *driver)
{
	device_t child;
	DEVICE_IDENTIFY(driver, dev);
	TAILQ_FOREACH(child, &dev->children, link) {
		if (child->state == DS_NOTPRESENT ||
		    (child->flags & DF_REBID))
			device_probe_and_attach(child);
	}
}
void bus_generic_driver_added ( device_t dev , driver_t * driver ) { device_t child ; DEVICE_IDENTIFY ( driver , dev ) ; TAILQ_FOREACH ( child , & dev -> children , link ) { if ( child -> state == DS_NOTPRESENT || ( child -> flags & DF_REBID ) ) device_probe_and_attach ( child ) ; } }
@brief Helper function for implementing BUS_DRIVER_ADDED().
@brief Helper function for implementing BUS_DRIVER_ADDED () .