[driver model] Add device_unregister_wait().
For those times when you need to wait for a device to unregister, before you continue on, this is device_unregister_wait(). It will block until all the references to the device go away, including references held by open sysfs files. This is probably most useful for modules that add and remove devices when they are loaded and unloaded. They must be sure that the devices that they have declared or allocated are completely torn down before the module is removed, lest unfreed memory get referenced or called.
Showing
Please register or sign in to comment