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

Commit b717727e authored by Claudio Scordino's avatar Claudio Scordino Committed by Greg Kroah-Hartman
Browse files

umc-bus.c: fix usage of device_trylock



Fix usage of device_trylock. It has the same semantics of mutex_trylock, so it
returns 1 if the lock has been acquired successfully.

Signed-off-by: default avatarClaudio Scordino <claudio@evidence.eu.com>
Signed-off-by: default avatarBruno Morelli <bruno@evidence.eu.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 6f602912
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -63,7 +63,7 @@ int umc_controller_reset(struct umc_dev *umc)
	struct device *parent = umc->dev.parent;
	int ret = 0;

	if (device_trylock(parent))
	if (!device_trylock(parent))
		return -EAGAIN;
	ret = device_for_each_child(parent, parent, umc_bus_pre_reset_helper);
	if (ret >= 0)