Changeset bad4a05 in mainline for uspace/lib/usbhost/src/bus.c
- Timestamp:
- 2018-01-11T04:12:06Z (6 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 0892663a
- Parents:
- a6c4597
- git-author:
- Ondřej Hlavatý <aearsis@…> (2018-01-11 01:31:42)
- git-committer:
- Ondřej Hlavatý <aearsis@…> (2018-01-11 04:12:06)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/usbhost/src/bus.c
ra6c4597 rbad4a05 112 112 * Invoke the device_remove bus operation. 113 113 */ 114 intbus_device_remove(device_t *dev)114 void bus_device_remove(device_t *dev) 115 115 { 116 116 assert(dev); 117 117 118 118 const bus_ops_t *ops = BUS_OPS_LOOKUP(dev->bus->ops, device_remove); 119 if (!ops) 120 return ENOTSUP; 119 assert(ops); 121 120 122 121 return ops->device_remove(dev); … … 266 265 267 266 fibril_mutex_lock(&device->guard); 268 const int r = ops->endpoint_unregister(ep); 269 if (!r) 270 device->endpoints[ep->endpoint] = NULL; 267 ops->endpoint_unregister(ep); 268 device->endpoints[ep->endpoint] = NULL; 271 269 fibril_mutex_unlock(&device->guard); 272 273 if (r)274 return r;275 270 276 271 /* Abort a transfer batch, if there was any */
Note:
See TracChangeset
for help on using the changeset viewer.