Changeset 41df71f9 in mainline for uspace/lib/drv/include/usb_iface.h
- Timestamp:
- 2017-11-02T14:29:15Z (7 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 887c9de
- Parents:
- 479e32d
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/drv/include/usb_iface.h
r479e32d r41df71f9 32 32 */ 33 33 /** @file 34 * @brief USB interface definition.34 * @brief USB device interface definition. 35 35 */ 36 36 … … 51 51 extern int usb_get_my_device_handle(async_exch_t *, devman_handle_t *); 52 52 53 extern int usb_reserve_default_address(async_exch_t *, usb_speed_t);54 extern int usb_release_default_address(async_exch_t *);55 56 extern int usb_device_enumerate(async_exch_t *, unsigned port);57 extern int usb_device_remove(async_exch_t *, unsigned port);58 59 extern int usb_register_endpoint(async_exch_t *, usb_endpoint_desc_t *);60 extern int usb_unregister_endpoint(async_exch_t *, usb_endpoint_desc_t *);61 extern int usb_read(async_exch_t *, usb_endpoint_t, uint64_t, void *, size_t,62 size_t *);63 extern int usb_write(async_exch_t *, usb_endpoint_t, uint64_t, const void *,64 size_t);65 66 /** Defined in usb/host/usb_transfer_batch.h */67 typedef struct usb_transfer_batch usb_transfer_batch_t;68 69 /** Callback for outgoing transfer - clone of usb_transfer_batch_callback_t */70 typedef int (*usb_iface_transfer_callback_t)(usb_transfer_batch_t *);71 72 53 /** USB device communication interface. */ 73 54 typedef struct { 74 55 int (*get_my_interface)(ddf_fun_t *, int *); 75 56 int (*get_my_device_handle)(ddf_fun_t *, devman_handle_t *); 76 77 int (*reserve_default_address)(ddf_fun_t *, usb_speed_t);78 int (*release_default_address)(ddf_fun_t *);79 80 int (*device_enumerate)(ddf_fun_t *, unsigned);81 int (*device_remove)(ddf_fun_t *, unsigned);82 83 int (*register_endpoint)(ddf_fun_t *, usb_endpoint_desc_t *);84 int (*unregister_endpoint)(ddf_fun_t *, usb_endpoint_desc_t *);85 86 int (*read)(ddf_fun_t *, usb_target_t,87 uint64_t, char *, size_t,88 usb_iface_transfer_callback_t, void *);89 int (*write)(ddf_fun_t *, usb_target_t,90 uint64_t, const char *, size_t,91 usb_iface_transfer_callback_t, void *);92 57 } usb_iface_t; 93 58
Note:
See TracChangeset
for help on using the changeset viewer.