From: David Brownell Date: Wed, 26 Apr 2006 21:39:11 +0000 (-0700) Subject: [PATCH] USB: fix bug in ohci-hcd.c ohci_restart() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=839ab1d4ce4dfd7e6c189391a82c584292488b41;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git [PATCH] USB: fix bug in ohci-hcd.c ohci_restart() A loop on a power-lost resume path used the wrong index. I suspect khubd has been working around such bugs. Noticed by Andreas Mohr . Signed-off-by: David Brownell Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/usb/host/ohci-hcd.c b/drivers/usb/host/ohci-hcd.c index 544f7589912..73f5a379d9b 100644 --- a/drivers/usb/host/ohci-hcd.c +++ b/drivers/usb/host/ohci-hcd.c @@ -863,7 +863,7 @@ static int ohci_restart (struct ohci_hcd *ohci) i = ohci->num_ports; while (i--) ohci_writel (ohci, RH_PS_PSS, - &ohci->regs->roothub.portstatus [temp]); + &ohci->regs->roothub.portstatus [i]); ohci_dbg (ohci, "restart complete\n"); } return 0;