diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-06-20 11:25:44 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-06-20 11:25:44 -0400 |
commit | af52739b922f656eb1f39016fabaabe4baeda2e2 (patch) | |
tree | 79a7aa810d0493cd0cf4adebac26d37f12e8b545 /drivers/usb/host/xhci.c | |
parent | 25ed6a5e97809129a1bc852b6b5c7d03baa112c4 (diff) | |
parent | 33688abb2802ff3a230bd2441f765477b94cc89e (diff) |
Merge 4.7-rc4 into staging-next
We want the fixes in here, and we can resolve a merge issue in
drivers/iio/industrialio-trigger.c
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/host/xhci.c')
-rw-r--r-- | drivers/usb/host/xhci.c | 29 |
1 files changed, 16 insertions, 13 deletions
diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c index fa7e1ef36cd9..f2f9518c53ab 100644 --- a/drivers/usb/host/xhci.c +++ b/drivers/usb/host/xhci.c | |||
@@ -685,20 +685,23 @@ void xhci_stop(struct usb_hcd *hcd) | |||
685 | u32 temp; | 685 | u32 temp; |
686 | struct xhci_hcd *xhci = hcd_to_xhci(hcd); | 686 | struct xhci_hcd *xhci = hcd_to_xhci(hcd); |
687 | 687 | ||
688 | if (xhci->xhc_state & XHCI_STATE_HALTED) | ||
689 | return; | ||
690 | |||
691 | mutex_lock(&xhci->mutex); | 688 | mutex_lock(&xhci->mutex); |
692 | spin_lock_irq(&xhci->lock); | ||
693 | xhci->xhc_state |= XHCI_STATE_HALTED; | ||
694 | xhci->cmd_ring_state = CMD_RING_STATE_STOPPED; | ||
695 | 689 | ||
696 | /* Make sure the xHC is halted for a USB3 roothub | 690 | if (!(xhci->xhc_state & XHCI_STATE_HALTED)) { |
697 | * (xhci_stop() could be called as part of failed init). | 691 | spin_lock_irq(&xhci->lock); |
698 | */ | 692 | |
699 | xhci_halt(xhci); | 693 | xhci->xhc_state |= XHCI_STATE_HALTED; |
700 | xhci_reset(xhci); | 694 | xhci->cmd_ring_state = CMD_RING_STATE_STOPPED; |
701 | spin_unlock_irq(&xhci->lock); | 695 | xhci_halt(xhci); |
696 | xhci_reset(xhci); | ||
697 | |||
698 | spin_unlock_irq(&xhci->lock); | ||
699 | } | ||
700 | |||
701 | if (!usb_hcd_is_primary_hcd(hcd)) { | ||
702 | mutex_unlock(&xhci->mutex); | ||
703 | return; | ||
704 | } | ||
702 | 705 | ||
703 | xhci_cleanup_msix(xhci); | 706 | xhci_cleanup_msix(xhci); |
704 | 707 | ||
@@ -4886,7 +4889,7 @@ int xhci_gen_setup(struct usb_hcd *hcd, xhci_get_quirks_t get_quirks) | |||
4886 | xhci->hcc_params2 = readl(&xhci->cap_regs->hcc_params2); | 4889 | xhci->hcc_params2 = readl(&xhci->cap_regs->hcc_params2); |
4887 | xhci_print_registers(xhci); | 4890 | xhci_print_registers(xhci); |
4888 | 4891 | ||
4889 | xhci->quirks = quirks; | 4892 | xhci->quirks |= quirks; |
4890 | 4893 | ||
4891 | get_quirks(dev, xhci); | 4894 | get_quirks(dev, xhci); |
4892 | 4895 | ||