Skip to content

Commit

Permalink
USB: EHCI restart speedup
Browse files Browse the repository at this point in the history
It is not necessary to powerdown the ports on ehci_pci_reinit() when the
chip reset already did that.  Removing this saves 20ms during restart
after poweroff paths (which OLPC uses a lot).

To ensure driver startup then behaves consistently, force a reset during
driver startup.  (Not doing this was an accident of some previous changes
to the init sequence.)

Make the corresponding change in the PS3 support.  It's not clear what
ehci-fsl should do here; it has similar code to the PS3.

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: David Brownell <dbrownell@users.sourceforge.net>
Cc: <rvinson@mvista.com>
Acked-by: Geoff Levand <geoffrey.levand@am.sony.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Marcelo Tosatti authored and Greg Kroah-Hartman committed Oct 12, 2007
1 parent 0eb0226 commit af1c51f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 deletions.
5 changes: 1 addition & 4 deletions drivers/usb/host/ehci-pci.c
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,6 @@ static int ehci_pci_reinit(struct ehci_hcd *ehci, struct pci_dev *pdev)
if (!retval)
ehci_dbg(ehci, "MWI active\n");

ehci_port_power(ehci, 0);

return 0;
}

Expand Down Expand Up @@ -156,8 +154,7 @@ static int ehci_pci_setup(struct usb_hcd *hcd)
break;
}

if (ehci_is_TDI(ehci))
ehci_reset(ehci);
ehci_reset(ehci);

/* at least the Genesys GL880S needs fixup here */
temp = HCS_N_CC(ehci->hcs_params) * HCS_N_PCC(ehci->hcs_params);
Expand Down
2 changes: 1 addition & 1 deletion drivers/usb/host/ehci-ps3.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ static int ps3_ehci_hc_reset(struct usb_hcd *hcd)
if (result)
return result;

ehci_port_power(ehci, 0);
ehci_reset(ehci);

return result;
}
Expand Down

0 comments on commit af1c51f

Please sign in to comment.