Commit d479c911789e14a19b86ca09b0b634f1449c8c6b

Authored by Ben Collins
Committed by Linus Torvalds
1 parent e2a666d52b

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 3735ba8db8e6 ("powerpc/usb: fix bug of CPU hang
when missing USB PHY clock"), which missed one return.

Signed-off-by: Ben Collins <ben.c@servergy.com>
Cc: Shengzhou Liu <Shengzhou.Liu@freescale.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff

drivers/usb/host/ehci-fsl.c
... ... @@ -222,7 +222,7 @@
222 222  
223 223 if (pdata->controller_ver < 0) {
224 224 dev_warn(hcd->self.controller, "Could not get controller version\n");
225   - return;
  225 + return -ENODEV;
226 226 }
227 227  
228 228 portsc = ehci_readl(ehci, &ehci->regs->port_status[port_offset]);