Changeset 93fb170c in mainline for uspace/srv/vfs/vfs_register.c
- Timestamp:
- 2011-01-08T18:51:31Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 15be932
- Parents:
- 8f748215 (diff), a523af4 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/vfs/vfs_register.c
r8f748215 r93fb170c 39 39 #include <ipc/services.h> 40 40 #include <async.h> 41 #include <async_rel.h>42 41 #include <fibril.h> 43 42 #include <fibril_synch.h> … … 111 110 void vfs_register(ipc_callid_t rid, ipc_call_t *request) 112 111 { 112 int phone; 113 113 114 dprintf("Processing VFS_REGISTER request received from %p.\n", 114 115 request->in_phone_hash); … … 136 137 137 138 link_initialize(&fs_info->fs_link); 138 fibril_mutex_initialize(&fs_info->phone_lock);139 139 fs_info->vfs_info = *vfs_info; 140 140 free(vfs_info); … … 186 186 return; 187 187 } 188 fs_info->phone = IPC_GET_ARG5(call); 188 189 phone = IPC_GET_ARG5(call); 190 async_session_create(&fs_info->session, phone); 189 191 ipc_answer_0(callid, EOK); 190 192 … … 200 202 list_remove(&fs_info->fs_link); 201 203 fibril_mutex_unlock(&fs_head_lock); 202 ipc_hangup(fs_info->phone); 204 async_session_destroy(&fs_info->session); 205 ipc_hangup(phone); 203 206 free(fs_info); 204 207 ipc_answer_0(callid, EINVAL); … … 214 217 list_remove(&fs_info->fs_link); 215 218 fibril_mutex_unlock(&fs_head_lock); 216 ipc_hangup(fs_info->phone); 219 async_session_destroy(&fs_info->session); 220 ipc_hangup(phone); 217 221 free(fs_info); 218 222 ipc_answer_0(callid, EINVAL); … … 269 273 if (fs->fs_handle == handle) { 270 274 fibril_mutex_unlock(&fs_head_lock); 271 fibril_mutex_lock(&fs->phone_lock); 272 phone = async_relation_create(fs->phone); 273 fibril_mutex_unlock(&fs->phone_lock); 275 phone = async_exchange_begin(&fs->session); 274 276 275 277 assert(phone > 0); … … 295 297 if (fs->fs_handle == handle) { 296 298 fibril_mutex_unlock(&fs_head_lock); 297 fibril_mutex_lock(&fs->phone_lock); 298 async_relation_destroy(fs->phone, phone); 299 fibril_mutex_unlock(&fs->phone_lock); 299 async_exchange_end(&fs->session, phone); 300 300 return; 301 301 }
Note:
See TracChangeset
for help on using the changeset viewer.