aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host
diff options
context:
space:
mode:
authorAlan Stern <stern@rowland.harvard.edu>2012-07-11 11:21:17 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-07-16 19:50:13 -0400
commit15be105b4a18c461b95fa683907f6da6deae1b75 (patch)
tree09d6f71f543957ce76776a51e01240cfee1fab67 /drivers/usb/host
parent631fe9d9d20e28fffdf750d12dd2cd275bd654e9 (diff)
USB: EHCI: remove unneeded suspend/resume code
This patch (as1566) removes the code in ehci-hcd's resume routines which tries to restart or cancel any transfers left active while the root hub or controller was asleep. This code isn't necessary, because all URBs are terminated before the root hub is suspended. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/host')
-rw-r--r--drivers/usb/host/ehci-hcd.c7
-rw-r--r--drivers/usb/host/ehci-hub.c13
2 files changed, 1 insertions, 19 deletions
diff --git a/drivers/usb/host/ehci-hcd.c b/drivers/usb/host/ehci-hcd.c
index 8727f4ea343f..ab7306de8d16 100644
--- a/drivers/usb/host/ehci-hcd.c
+++ b/drivers/usb/host/ehci-hcd.c
@@ -1312,13 +1312,6 @@ static int __maybe_unused ehci_resume(struct usb_hcd *hcd, bool hibernated)
1312 (void) ehci_halt(ehci); 1312 (void) ehci_halt(ehci);
1313 (void) ehci_reset(ehci); 1313 (void) ehci_reset(ehci);
1314 1314
1315 /* emptying the schedule aborts any urbs */
1316 spin_lock_irq(&ehci->lock);
1317 if (ehci->reclaim)
1318 end_unlink_async(ehci);
1319 ehci_work(ehci);
1320 spin_unlock_irq(&ehci->lock);
1321
1322 ehci_writel(ehci, ehci->command, &ehci->regs->command); 1315 ehci_writel(ehci, ehci->command, &ehci->regs->command);
1323 ehci_writel(ehci, FLAG_CF, &ehci->regs->configured_flag); 1316 ehci_writel(ehci, FLAG_CF, &ehci->regs->configured_flag);
1324 ehci_readl(ehci, &ehci->regs->command); /* unblock posted writes */ 1317 ehci_readl(ehci, &ehci->regs->command); /* unblock posted writes */
diff --git a/drivers/usb/host/ehci-hub.c b/drivers/usb/host/ehci-hub.c
index b3e2d66e95bb..1daaa96f527d 100644
--- a/drivers/usb/host/ehci-hub.c
+++ b/drivers/usb/host/ehci-hub.c
@@ -424,23 +424,12 @@ static int ehci_bus_resume (struct usb_hcd *hcd)
424 ehci_vdbg (ehci, "resumed port %d\n", i + 1); 424 ehci_vdbg (ehci, "resumed port %d\n", i + 1);
425 } 425 }
426 } 426 }
427 (void) ehci_readl(ehci, &ehci->regs->command);
428
429 /* maybe re-activate the schedule(s) */
430 temp = 0;
431 if (ehci->async->qh_next.qh)
432 temp |= CMD_ASE;
433 if (ehci->periodic_sched)
434 temp |= CMD_PSE;
435 if (temp) {
436 ehci->command |= temp;
437 ehci_writel(ehci, ehci->command, &ehci->regs->command);
438 }
439 427
440 ehci->next_statechange = jiffies + msecs_to_jiffies(5); 428 ehci->next_statechange = jiffies + msecs_to_jiffies(5);
441 429
442 /* Now we can safely re-enable irqs */ 430 /* Now we can safely re-enable irqs */
443 ehci_writel(ehci, INTR_MASK, &ehci->regs->intr_enable); 431 ehci_writel(ehci, INTR_MASK, &ehci->regs->intr_enable);
432 (void) ehci_readl(ehci, &ehci->regs->intr_enable);
444 433
445 spin_unlock_irq (&ehci->lock); 434 spin_unlock_irq (&ehci->lock);
446 ehci_handover_companion_ports(ehci); 435 ehci_handover_companion_ports(ehci);