That's not the issue. We _don't_ allow all of the operations in
device_del() preceding the call to device_pm_remove(). In particular,
the call to the device's driver's remove method will deadlock because
device_release_driver() always has to acquire dev->sem.
No -- the whole idea here is to print an error message in the system
log if a driver's resume method tries to call device_del(). Deadlock
is unavoidable in this case, but at least we'll know which driver is
guilty.
Alan Stern
--