void driver_unregister (struct device_driver * drv);
Again, we pass off most of the work to the bus-level call.
Though, once that is done, we attempt to take drv->unload_sem. This will block until the driver refcount reaches 0, and it is released. Only modular drivers will call this function, and we have to guarantee that it won't complete, letting the driver unload until all references are gone.