Changeset b4b534ac in mainline for uspace/drv/bus/usb/ohci/hw_struct/endpoint_descriptor.c
- Timestamp:
- 2016-07-22T08:24:47Z (9 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- f76d2c2
- Parents:
- 5b18137 (diff), 8351f9a4 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/ohci/hw_struct/endpoint_descriptor.c
r5b18137 rb4b534ac 32 32 * @brief OHCI driver 33 33 */ 34 35 #include <assert.h> 36 #include <macros.h> 37 #include <mem.h> 38 39 #include <usb/usb.h> 40 #include <usb/host/utils/malloc32.h> 41 42 #include "mem_access.h" 43 34 44 #include "endpoint_descriptor.h" 35 45 … … 48 58 * @param td TD to put in the list. 49 59 * 50 * If @param ep is NULL, dummy ED is init alized with only skip flag set.60 * If @param ep is NULL, dummy ED is initialized with only skip flag set. 51 61 */ 52 62 void ed_init(ed_t *instance, const endpoint_t *ep, const td_t *td) 53 63 { 54 64 assert(instance); 55 memset(instance, 0, sizeof( ed_t));65 memset(instance, 0, sizeof(*instance)); 56 66 57 67 if (ep == NULL) { … … 61 71 return; 62 72 } 63 /* Non-dummy ED must have TD assigned */73 /* Non-dummy ED must have corresponding EP and TD assigned */ 64 74 assert(td); 75 assert(ep); 76 assert(ep->direction < ARRAY_SIZE(dir)); 65 77 66 78 /* Status: address, endpoint nr, direction mask and max packet size. */ … … 77 89 78 90 /* Isochronous format flag */ 91 // TODO: We need iTD instead of TD for iso transfers 79 92 if (ep->transfer_type == USB_TRANSFER_ISOCHRONOUS) 80 93 OHCI_MEM32_SET(instance->status, ED_STATUS_F_FLAG);
Note:
See TracChangeset
for help on using the changeset viewer.