Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset 6b433a8 in mainline for uspace/drv/bus/usb/xhci/transfers.c


Ignore:
Timestamp:
2017-11-20T19:14:31Z (4 years ago)
Author:
Salmelu <salmelu@…>
Branches:
lfn, master
Children:
27b0ea0
Parents:
d3086873
Message:

Isochronous transfers - endpoint initialization

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/xhci/transfers.c

    rd3086873 r6b433a8  
    287287        isoch_transfer->size = transfer->batch.buffer_size;
    288288        if (isoch_transfer->size > 0) {
    289                 memcpy(isoch_transfer->data_virt, transfer->batch.buffer, isoch_transfer->size);
    290         }
    291 
    292         trb.parameter = isoch_transfer->data_phys;
     289                memcpy(isoch_transfer->data.virt, transfer->batch.buffer, isoch_transfer->size);
     290        }
     291
     292        trb.parameter = isoch_transfer->data.phys;
    293293
    294294        xhci_trb_ring_t *ring = get_ring(hc, transfer);
     
    341341        if (transfer->batch.buffer_size <= isoch_transfer->size) {
    342342                if (transfer->batch.buffer_size > 0) {
    343                         memcpy(transfer->batch.buffer, isoch_transfer->data_virt, transfer->batch.buffer_size);
     343                        memcpy(transfer->batch.buffer, isoch_transfer->data.virt, transfer->batch.buffer_size);
    344344                }
    345345                if (transfer->batch.buffer_size < isoch_transfer->size) {
     
    349349        }
    350350        else {
    351                 memcpy(transfer->batch.buffer, isoch_transfer->data_virt, isoch_transfer->size);
     351                memcpy(transfer->batch.buffer, isoch_transfer->data.virt, isoch_transfer->size);
    352352                transfer->batch.transfered_size = isoch_transfer->size;
    353353        }
     
    357357        xhci_trb_clean(&trb);
    358358
    359         trb.parameter = isoch_transfer->data_phys;
     359        trb.parameter = isoch_transfer->data.phys;
    360360        isoch_transfer->size = xhci_ep->isoch_max_size;
    361361
Note: See TracChangeset for help on using the changeset viewer.