Changeset d8b275d in mainline for uspace/drv/ohci/hw_struct/endpoint_descriptor.h
- Timestamp:
- 2011-04-14T08:24:29Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 5e07e2b5
- Parents:
- 3f2af64 (diff), 34e8bab (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/ohci/hw_struct/endpoint_descriptor.h
r3f2af64 rd8b275d 53 53 #define ED_STATUS_D_MASK (0x3) /* direction */ 54 54 #define ED_STATUS_D_SHIFT (11) 55 #define ED_STATUS_D_ IN(0x1)56 #define ED_STATUS_D_ OUT(0x2)55 #define ED_STATUS_D_OUT (0x1) 56 #define ED_STATUS_D_IN (0x2) 57 57 #define ED_STATUS_D_TRANSFER (0x3) 58 58 … … 81 81 void ed_init(ed_t *instance, endpoint_t *ep); 82 82 83 static inline void ed_ add_tds(ed_t *instance, td_t *head, td_t *tail)83 static inline void ed_set_td(ed_t *instance, td_t *td) 84 84 { 85 85 assert(instance); 86 instance->td_head = addr_to_phys(head) & ED_TDHEAD_PTR_MASK; 87 instance->td_tail = addr_to_phys(tail) & ED_TDTAIL_PTR_MASK; 86 uintptr_t pa = addr_to_phys(td); 87 instance->td_head = 88 ((pa & ED_TDHEAD_PTR_MASK) 89 | (instance->td_head & ~ED_TDHEAD_PTR_MASK)); 90 instance->td_tail = pa & ED_TDTAIL_PTR_MASK; 91 } 92 93 static inline void ed_set_end_td(ed_t *instance, td_t *td) 94 { 95 assert(instance); 96 uintptr_t pa = addr_to_phys(td); 97 instance->td_tail = pa & ED_TDTAIL_PTR_MASK; 88 98 } 89 99 … … 96 106 instance->next = pa; 97 107 } 98 99 108 #endif 100 109 /**
Note:
See TracChangeset
for help on using the changeset viewer.