Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 135dee0c authored by Rafael J. Wysocki's avatar Rafael J. Wysocki Committed by Greg Kroah-Hartman
Browse files

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: default avatarRafael J. Wysocki <rjw@sisk.pl>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 1b3cbec1
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -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,