Changeset bdb23c63 in mainline
- Timestamp:
- 2011-12-14T14:12:44Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 22ecbde
- Parents:
- cbd568b
- Location:
- uspace/lib/usbdev
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/usbdev/include/usb/dev/driver.h
rcbd568b rbdb23c63 72 72 /** USB device structure. */ 73 73 typedef struct { 74 /** Connection to USB hc, used by wire and arbitrary requests. */ 74 75 usb_hc_connection_t hc_conn; 75 76 /** Connection backing the pipes. -
uspace/lib/usbdev/include/usb/dev/pipes.h
rcbd568b rbdb23c63 39 39 #include <ddf/driver.h> 40 40 #include <fibril_synch.h> 41 #include <async.h>42 41 #include <usb/usb.h> 43 42 #include <usb/descriptor.h> … … 46 45 #define CTRL_PIPE_MIN_PACKET_SIZE 8 47 46 /** Abstraction of a logical connection to USB device endpoint. 48 * It encapsulates endpoint attributes (transfer type etc.) as well 49 * as information about currently running sessions. 47 * It encapsulates endpoint attributes (transfer type etc.). 50 48 * This endpoint must be bound with existing usb_device_connection_t 51 49 * (i.e. the wire to send data over). 52 *53 * Locking order: if you want to lock both mutexes54 * (@c guard and @c hc_sess_mutex), lock @c guard first.55 * It is not necessary to lock @c guard if you want to lock @c hc_sess_mutex56 * only.57 50 */ 58 51 typedef struct { 59 /** Guard of the whole pipe. */60 fibril_mutex_t guard;61 62 52 /** The connection used for sending the data. */ 63 53 usb_device_connection_t *wire; -
uspace/lib/usbdev/src/pipes.c
rcbd568b rbdb23c63 311 311 assert(connection); 312 312 313 fibril_mutex_initialize(&pipe->guard);314 313 pipe->wire = connection; 315 314 pipe->endpoint_no = endpoint_no;
Note:
See TracChangeset
for help on using the changeset viewer.