1

ssb: remove unreachable code

The return value of ssb_bus_unregister can only be 0 or -1, so this
condition if (err == -EBUSY) will not hold, so delete it.

Signed-off-by: Tian Tao <tiantao6@hisilicon.com>
Acked-by: Michael Büsch <m@bues.ch>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
Link: https://lore.kernel.org/r/1621306352-3632-1-git-send-email-tiantao6@hisilicon.com
This commit is contained in:
Tian Tao 2021-05-18 10:52:32 +08:00 committed by Kalle Valo
parent 47ec636f7a
commit 233bc28372

View File

@ -434,9 +434,7 @@ void ssb_bus_unregister(struct ssb_bus *bus)
int err;
err = ssb_gpio_unregister(bus);
if (err == -EBUSY)
pr_debug("Some GPIOs are still in use\n");
else if (err)
if (err)
pr_debug("Can not unregister GPIO driver: %i\n", err);
ssb_buses_lock();