mirror of
https://github.com/torvalds/linux.git
synced 2024-12-04 01:51:34 +00:00
driver core: Remove dpm_sysfs_remove() from error path of device_add()
Since device_pm_remove(dev) calls dpm_sysfs_remove(dev), it's incorrect to call the latter after the former in the device_add() error path. Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
1b3cbec1dc
commit
135dee0cd0
@ -839,7 +839,6 @@ int device_add(struct device *dev)
|
||||
return error;
|
||||
BusError:
|
||||
device_pm_remove(dev);
|
||||
dpm_sysfs_remove(dev);
|
||||
PMError:
|
||||
if (dev->bus)
|
||||
blocking_notifier_call_chain(&dev->bus->p->bus_notifier,
|
||||
|
Loading…
Reference in New Issue
Block a user