Changeset a210bc7 in mainline
- Timestamp:
- 2011-03-09T14:03:58Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 84226f0
- Parents:
- 242b4bb
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/fs/ext2fs/ext2fs_ops.c
r242b4bb ra210bc7 102 102 */ 103 103 static LIST_INITIALIZE(instance_list); 104 static FIBRIL_MUTEX_INITIALIZE(instance_list_mutex); 104 105 105 106 /** … … 130 131 link_t *link; 131 132 ext2fs_instance_t *tmp; 133 134 fibril_mutex_lock(&instance_list_mutex); 132 135 133 136 if (list_empty(&instance_list)) { 134 137 EXT2FS_DBG("list empty"); 138 fibril_mutex_unlock(&instance_list_mutex); 135 139 return EINVAL; 136 140 } … … 141 145 if (tmp->devmap_handle == devmap_handle) { 142 146 *inst = tmp; 147 fibril_mutex_unlock(&instance_list_mutex); 143 148 return EOK; 144 149 } … … 146 151 147 152 EXT2FS_DBG("not found"); 153 154 fibril_mutex_unlock(&instance_list_mutex); 148 155 return EINVAL; 149 156 } … … 462 469 ext2fs_instance_t *inst; 463 470 464 465 466 471 /* Accept the mount options */ 467 472 char *opts; … … 513 518 inst->devmap_handle = devmap_handle; 514 519 inst->filesystem = fs; 520 521 fibril_mutex_lock(&instance_list_mutex); 515 522 list_append(&inst->link, &instance_list); 523 fibril_mutex_unlock(&instance_list_mutex); 516 524 517 525 async_answer_0(rid, EOK); … … 541 549 542 550 // Remove the instance from list 551 fibril_mutex_lock(&instance_list_mutex); 543 552 list_remove(&inst->link); 553 fibril_mutex_unlock(&instance_list_mutex); 554 544 555 ext2_filesystem_fini(inst->filesystem); 545 556
Note:
See TracChangeset
for help on using the changeset viewer.