Changeset 32fb6bce in mainline for uspace/drv/bus/usb/vhc/vhcd.h
- Timestamp:
- 2017-12-18T22:50:21Z (6 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 7f70d1c
- Parents:
- 1ea0bbf
- git-author:
- Ondřej Hlavatý <aearsis@…> (2017-12-18 22:04:50)
- git-committer:
- Ondřej Hlavatý <aearsis@…> (2017-12-18 22:50:21)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/vhc/vhcd.h
r1ea0bbf r32fb6bce 39 39 #include <usbvirt/device.h> 40 40 #include <async.h> 41 #include <macros.h> 41 42 42 43 #include <usb/host/hcd.h> 43 44 #include <usb/host/usb2_bus.h> 45 #include <usb/host/usb_transfer_batch.h> 44 46 45 47 #define NAME "vhc" … … 56 58 57 59 typedef struct { 58 uint32_t magic; 60 hc_device_t base; 61 62 usb2_bus_t bus; 63 ddf_fun_t *virtual_fun; 59 64 list_t devices; 60 65 fibril_mutex_t guard; 61 66 usbvirt_device_t hub; 62 usb2_bus_t bus;63 67 } vhc_data_t; 64 68 65 69 typedef struct { 70 usb_transfer_batch_t batch; 66 71 link_t link; 67 usb_transfer_batch_t *batch;68 72 } vhc_transfer_t; 73 74 static inline vhc_data_t *hcd_to_vhc(hc_device_t *hcd) 75 { 76 assert(hcd); 77 return (vhc_data_t *) hcd; 78 } 79 80 static inline vhc_data_t *bus_to_vhc(bus_t *bus) 81 { 82 assert(bus); 83 return member_to_inst(bus, vhc_data_t, bus); 84 } 69 85 70 86 void on_client_close(ddf_fun_t *fun); … … 77 93 void vhc_virtdev_unplug(vhc_data_t *, uintptr_t); 78 94 79 int vhc_init(vhc_data_t * instance, hcd_t *);80 int vhc_schedule( hcd_t *hcd, usb_transfer_batch_t *batch);95 int vhc_init(vhc_data_t *); 96 int vhc_schedule(usb_transfer_batch_t *); 81 97 int vhc_transfer_queue_processor(void *arg); 82 98
Note:
See TracChangeset
for help on using the changeset viewer.