Changeset b4b534ac in mainline for uspace/drv/bus/usb/ehci/hw_struct/link_pointer.h
- 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 moved
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/ehci/hw_struct/link_pointer.h
r5b18137 rb4b534ac 1 1 /* 2 * Copyright (c) 201 1 Vojtech Horky2 * Copyright (c) 2013 Jan Vesely 3 3 * All rights reserved. 4 4 * … … 26 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 27 */ 28 29 /** @addtogroup libusb 28 /** @addtogroup drvusbehci 30 29 * @{ 31 30 */ 32 31 /** @file 33 * Implementations of DDF interfaces functions.32 * @brief EHCI driver 34 33 */ 35 36 #ifndef LIBUSB_DDFIFACE_H_ 37 #define LIBUSB_DDFIFACE_H_ 34 #ifndef DRV_EHCI_HW_STRUCT_LINK_POINTER_H 35 #define DRV_EHCI_HW_STRUCT_LINK_POINTER_H 38 36 39 37 #include <sys/types.h> 40 #include <usb_iface.h>41 38 42 extern int usb_iface_get_hc_handle_device_impl(ddf_fun_t *, devman_handle_t *); 43 extern int usb_iface_get_my_address_forward_impl(ddf_fun_t *, usb_address_t *); 44 extern usb_iface_t usb_iface_hub_impl; 39 /** EHCI link pointer, used by many data structures */ 40 typedef volatile uint32_t link_pointer_t; 45 41 46 extern int usb_iface_get_my_address_from_device_data(ddf_fun_t *, usb_address_t *); 47 extern usb_iface_t usb_iface_hub_child_impl; 42 #define LINK_POINTER_ADDRESS_MASK 0xfffffff0 /* upper 28 bits */ 48 43 49 extern int usb_iface_get_hc_handle_hc_impl(ddf_fun_t *, devman_handle_t *); 44 #define LINK_POINTER_TERMINATE_FLAG (1 << 0) 45 46 enum { 47 LINK_POINTER_TYPE_iTD = 0x0 << 1, 48 LINK_POINTER_TYPE_QH = 0x1 << 1, 49 LINK_POINTER_TYPE_siTD = 0x2 << 1, 50 LINK_POINTER_TYPE_FSTN = 0x3 << 1, 51 LINK_POINTER_TYPE_MASK = 0x3 << 1, 52 }; 53 54 #define LINK_POINTER_QH(address) \ 55 ((address & LINK_POINTER_ADDRESS_MASK) | LINK_POINTER_TYPE_QH) 56 57 #define LINK_POINTER_TD(address) \ 58 (address & LINK_POINTER_ADDRESS_MASK) 59 60 #define LINK_POINTER_TERM \ 61 ((link_pointer_t)LINK_POINTER_TERMINATE_FLAG) 50 62 51 63 #endif 52 53 64 /** 54 65 * @}
Note:
See TracChangeset
for help on using the changeset viewer.