Changeset 9848c77 in mainline for uspace/lib/usbhost
- Timestamp:
 - 2018-01-11T04:14:40Z (8 years ago)
 - Branches:
 - lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
 - Children:
 - 17783bf
 - Parents:
 - 0892663a
 - git-author:
 - Ondřej Hlavatý <aearsis@…> (2018-01-11 04:10:46)
 - git-committer:
 - Ondřej Hlavatý <aearsis@…> (2018-01-11 04:14:40)
 - Location:
 - uspace/lib/usbhost
 - Files:
 - 
      
- 3 edited
 
- 
          
  include/usb/host/bus.h (modified) (2 diffs)
 - 
          
  src/bus.c (modified) (3 diffs)
 - 
          
  src/ddf_helpers.c (modified) (1 diff)
 
 
Legend:
- Unmodified
 - Added
 - Removed
 
- 
      
uspace/lib/usbhost/include/usb/host/bus.h
r0892663a r9848c77 103 103 /* Operations on device */ 104 104 int (*device_enumerate)(device_t *); 105 void (*device_ remove)(device_t *);105 void (*device_gone)(device_t *); 106 106 int (*device_online)(device_t *); /**< Optional */ 107 107 void (*device_offline)(device_t *); /**< Optional */ … … 149 149 150 150 int bus_device_enumerate(device_t *); 151 void bus_device_ remove(device_t *);151 void bus_device_gone(device_t *); 152 152 153 153 int bus_device_online(device_t *);  - 
      
uspace/lib/usbhost/src/bus.c
r0892663a r9848c77 167 167 */ 168 168 fibril_mutex_unlock(&dev->guard); 169 bus_device_ remove(child);169 bus_device_gone(child); 170 170 fibril_mutex_lock(&dev->guard); 171 171 } … … 176 176 * Resolve a USB device that is gone. 177 177 */ 178 void bus_device_ remove(device_t *dev)178 void bus_device_gone(device_t *dev) 179 179 { 180 180 assert(dev); 181 181 assert(dev->fun == NULL); 182 182 183 const bus_ops_t *ops = BUS_OPS_LOOKUP(dev->bus->ops, device_ remove);183 const bus_ops_t *ops = BUS_OPS_LOOKUP(dev->bus->ops, device_gone); 184 184 assert(ops); 185 185 … … 212 212 213 213 /* Tell the HC to release its resources. */ 214 ops->device_ remove(dev);214 ops->device_gone(dev); 215 215 216 216 /* Release the EP0 bus reference */  - 
      
uspace/lib/usbhost/src/ddf_helpers.c
r0892663a r9848c77 354 354 assert(victim->hub == hub); 355 355 356 bus_device_ remove(victim);356 bus_device_gone(victim); 357 357 return EOK; 358 358 }  
  Note:
 See   TracChangeset
 for help on using the changeset viewer.
  