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

Commit d479c911 authored by Ben Collins's avatar Ben Collins Committed by Linus Torvalds
Browse files

USB: ehci-fsl: Return valid error in ehci_fsl_setup_phy



ehci_fsl_setup_phy is supposed to return an int, but had a void return
value in the case of controller_ver being invalid.

Introduced by commit 3735ba8d ("powerpc/usb: fix bug of CPU hang
when missing USB PHY clock"), which missed one return.

Signed-off-by: default avatarBen Collins <ben.c@servergy.com>
Cc: Shengzhou Liu <Shengzhou.Liu@freescale.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent e2a666d5
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -222,7 +222,7 @@ static int ehci_fsl_setup_phy(struct usb_hcd *hcd,


	if (pdata->controller_ver < 0) {
	if (pdata->controller_ver < 0) {
		dev_warn(hcd->self.controller, "Could not get controller version\n");
		dev_warn(hcd->self.controller, "Could not get controller version\n");
		return;
		return -ENODEV;
	}
	}


	portsc = ehci_readl(ehci, &ehci->regs->port_status[port_offset]);
	portsc = ehci_readl(ehci, &ehci->regs->port_status[port_offset]);