Lines 933-946
static int xhci_invalidate_cancelled_tds(struct xhci_virt_ep *ep)
Link Here
|
933 |
continue; |
933 |
continue; |
934 |
} |
934 |
} |
935 |
/* |
935 |
/* |
936 |
* If ring stopped on the TD we need to cancel, then we have to |
936 |
* If a ring stopped on the TD we need to cancel then we have to |
937 |
* move the xHC endpoint ring dequeue pointer past this TD. |
937 |
* move the xHC endpoint ring dequeue pointer past this TD. |
|
|
938 |
* Rings halted due to STALL may show hw_deq is past the stalled |
939 |
* TD, but still require a set TR Deq command to flush xHC cache. |
938 |
*/ |
940 |
*/ |
939 |
hw_deq = xhci_get_hw_deq(xhci, ep->vdev, ep->ep_index, |
941 |
hw_deq = xhci_get_hw_deq(xhci, ep->vdev, ep->ep_index, |
940 |
td->urb->stream_id); |
942 |
td->urb->stream_id); |
941 |
hw_deq &= ~0xf; |
943 |
hw_deq &= ~0xf; |
942 |
|
944 |
|
943 |
if (trb_in_td(xhci, td->start_seg, td->first_trb, |
945 |
if (td->cancel_status == TD_HALTED) { |
|
|
946 |
cached_td = td; |
947 |
} else if (trb_in_td(xhci, td->start_seg, td->first_trb, |
944 |
td->last_trb, hw_deq, false)) { |
948 |
td->last_trb, hw_deq, false)) { |
945 |
switch (td->cancel_status) { |
949 |
switch (td->cancel_status) { |
946 |
case TD_CLEARED: /* TD is already no-op */ |
950 |
case TD_CLEARED: /* TD is already no-op */ |
947 |
- |
|
|