Changes in uspace/srv/devman/dev.c [c3d9aaf5:498ced1] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/devman/dev.c
rc3d9aaf5 r498ced1 1 1 /* 2 * Copyright (c) 2025 Jiri Svoboda3 2 * Copyright (c) 2010 Lenka Trochtova 4 3 * All rights reserved. … … 51 50 refcount_init(&dev->refcnt); 52 51 list_initialize(&dev->functions); 53 fibril_mutex_initialize(&dev->state_lock);54 fibril_condvar_initialize(&dev->state_cv);55 52 link_initialize(&dev->driver_devices); 56 53 … … 90 87 if (refcount_down(&dev->refcnt)) 91 88 delete_dev_node(dev); 92 }93 94 /** Wait until the device node enters stable state.95 *96 * @param dev Device node97 */98 void dev_wait_stable(dev_node_t *dev)99 {100 fibril_mutex_lock(&dev->state_lock);101 while (dev->state == DEVICE_ATTACHING)102 fibril_condvar_wait(&dev->state_cv, &dev->state_lock);103 fibril_mutex_unlock(&dev->state_lock);104 89 } 105 90
Note:
See TracChangeset
for help on using the changeset viewer.