mirror of https://gitee.com/openkylin/linux.git
driver core: replace open-coded device_lock_assert()
Using the right wrapper makes it easier to associate this assert statement with the device_[un]lock() helpers. Signed-off-by: Julian Wiedmann <jwi@linux.ibm.com> Link: https://lore.kernel.org/r/20210512141054.2180373-1-jwi@linux.ibm.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
d616f56d34
commit
8c60a14104
|
@ -3437,7 +3437,7 @@ bool kill_device(struct device *dev)
|
|||
* to run while we are tearing out the bus/class/sysfs from
|
||||
* underneath the device.
|
||||
*/
|
||||
lockdep_assert_held(&dev->mutex);
|
||||
device_lock_assert(dev);
|
||||
|
||||
if (dev->p->dead)
|
||||
return false;
|
||||
|
|
Loading…
Reference in New Issue