Ignore:
Timestamp:
2017-09-29T21:46:08Z (7 years ago)
Author:
Ondřej Hlavatý <aearsis@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
cc9ac7c
Parents:
ab5a0830
Message:

xhci commands: embed TRB into the command structure

Previously, a pointer into the TRB ring itself was contained. That could cause
problems, because the ring does not care and can move/deallocate segments, or
overwrite TRBs inside. To solve the original issue, xhci_trb_ring_enqueue can
now fill physical address of the TRB enqueued.

Also, this eliminates the need to track ownage of TRB.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/xhci/hw_struct/trb.h

    rab5a0830 r548c123  
    138138    dst->status = src->status;
    139139    dst->control = src->control;
     140}
     141
     142static inline void xhci_trb_clean(xhci_trb_t *trb)
     143{
     144        memset(trb, 0, sizeof(*trb));
    140145}
    141146
Note: See TracChangeset for help on using the changeset viewer.