diff options
Diffstat (limited to 'drivers/usb/host/ehci-q.c')
-rw-r--r-- | drivers/usb/host/ehci-q.c | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/drivers/usb/host/ehci-q.c b/drivers/usb/host/ehci-q.c index 1976b1b3778c..3192f683f807 100644 --- a/drivers/usb/host/ehci-q.c +++ b/drivers/usb/host/ehci-q.c | |||
@@ -93,22 +93,6 @@ qh_update (struct ehci_hcd *ehci, struct ehci_qh *qh, struct ehci_qtd *qtd) | |||
93 | qh->hw_qtd_next = QTD_NEXT(ehci, qtd->qtd_dma); | 93 | qh->hw_qtd_next = QTD_NEXT(ehci, qtd->qtd_dma); |
94 | qh->hw_alt_next = EHCI_LIST_END(ehci); | 94 | qh->hw_alt_next = EHCI_LIST_END(ehci); |
95 | 95 | ||
96 | /* Except for control endpoints, we make hardware maintain data | ||
97 | * toggle (like OHCI) ... here (re)initialize the toggle in the QH, | ||
98 | * and set the pseudo-toggle in udev. Only usb_clear_halt() will | ||
99 | * ever clear it. | ||
100 | */ | ||
101 | if (!(qh->hw_info1 & cpu_to_hc32(ehci, 1 << 14))) { | ||
102 | unsigned is_out, epnum; | ||
103 | |||
104 | is_out = !(qtd->hw_token & cpu_to_hc32(ehci, 1 << 8)); | ||
105 | epnum = (hc32_to_cpup(ehci, &qh->hw_info1) >> 8) & 0x0f; | ||
106 | if (unlikely (!usb_gettoggle (qh->dev, epnum, is_out))) { | ||
107 | qh->hw_token &= ~cpu_to_hc32(ehci, QTD_TOGGLE); | ||
108 | usb_settoggle (qh->dev, epnum, is_out, 1); | ||
109 | } | ||
110 | } | ||
111 | |||
112 | /* HC must see latest qtd and qh data before we clear ACTIVE+HALT */ | 96 | /* HC must see latest qtd and qh data before we clear ACTIVE+HALT */ |
113 | wmb (); | 97 | wmb (); |
114 | qh->hw_token &= cpu_to_hc32(ehci, QTD_TOGGLE | QTD_STS_PING); | 98 | qh->hw_token &= cpu_to_hc32(ehci, QTD_TOGGLE | QTD_STS_PING); |
@@ -850,7 +834,6 @@ done: | |||
850 | qh->qh_state = QH_STATE_IDLE; | 834 | qh->qh_state = QH_STATE_IDLE; |
851 | qh->hw_info1 = cpu_to_hc32(ehci, info1); | 835 | qh->hw_info1 = cpu_to_hc32(ehci, info1); |
852 | qh->hw_info2 = cpu_to_hc32(ehci, info2); | 836 | qh->hw_info2 = cpu_to_hc32(ehci, info2); |
853 | usb_settoggle (urb->dev, usb_pipeendpoint (urb->pipe), !is_input, 1); | ||
854 | qh_refresh (ehci, qh); | 837 | qh_refresh (ehci, qh); |
855 | return qh; | 838 | return qh; |
856 | } | 839 | } |
@@ -881,7 +864,7 @@ static void qh_link_async (struct ehci_hcd *ehci, struct ehci_qh *qh) | |||
881 | } | 864 | } |
882 | } | 865 | } |
883 | 866 | ||
884 | /* clear halt and/or toggle; and maybe recover from silicon quirk */ | 867 | /* clear halt and maybe recover from silicon quirk */ |
885 | if (qh->qh_state == QH_STATE_IDLE) | 868 | if (qh->qh_state == QH_STATE_IDLE) |
886 | qh_refresh (ehci, qh); | 869 | qh_refresh (ehci, qh); |
887 | 870 | ||