Changeset 2b61945 in mainline for uspace/drv/bus/usb/xhci/trb_ring.c
- Timestamp:
- 2017-10-22T03:47:41Z (6 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 2e5aea1
- Parents:
- 766043c
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/xhci/trb_ring.c
r766043c r2b61945 155 155 } 156 156 157 static bool trb_generates_interrupt(xhci_trb_t *trb) 158 { 159 return TRB_TYPE(*trb) >= XHCI_TRB_TYPE_ENABLE_SLOT_CMD 160 || TRB_IOC(*trb); 161 } 162 157 163 /** 158 164 * Enqueue TDs composed of TRBs. … … 188 194 xhci_trb_t *trb = first_trb; 189 195 for (size_t i = 0; i < trbs; ++i, ++trb) { 196 if (trb_generates_interrupt(trb)) { 197 if (*phys) 198 return ENOTSUP; 199 *phys = trb_ring_enqueue_phys(ring); 200 } 201 190 202 ring->enqueue_trb++; 191 203 … … 205 217 trb = first_trb; 206 218 for (size_t i = 0; i < trbs; ++i, ++trb) { 207 if (phys && i == trbs - 1)208 *phys = trb_ring_enqueue_phys(ring);209 210 219 xhci_trb_set_cycle(trb, ring->pcs); 211 220 xhci_trb_copy(ring->enqueue_trb, trb);
Note:
See TracChangeset
for help on using the changeset viewer.