Changeset 41811af in mainline for uspace/srv/fs/fat/fat.c
- Timestamp:
- 2011-06-10T10:14:26Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- ab547063
- Parents:
- 9536e6e (diff), 390d80d (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/fs/fat/fat.c
r9536e6e r41811af 39 39 #include "fat.h" 40 40 #include <ipc/services.h> 41 #include < ipc/ns.h>41 #include <ns.h> 42 42 #include <async.h> 43 43 #include <errno.h> … … 88 88 89 89 dprintf(NAME ": connection opened\n"); 90 while (1) {91 ipc_callid_t callid;90 91 while (true) { 92 92 ipc_call_t call; 93 94 callid = async_get_call(&call); 95 switch (IPC_GET_IMETHOD(call)) { 96 case IPC_M_PHONE_HUNGUP: 93 ipc_callid_t callid = async_get_call(&call); 94 95 if (!IPC_GET_IMETHOD(call)) 97 96 return; 97 98 switch (IPC_GET_IMETHOD(call)) { 98 99 case VFS_OUT_MOUNTED: 99 100 fat_mounted(callid, &call); … … 144 145 int main(int argc, char **argv) 145 146 { 146 int vfs_phone;147 int rc;148 149 147 printf(NAME ": HelenOS FAT file system server\n"); 150 151 rc = fat_idx_init();148 149 int rc = fat_idx_init(); 152 150 if (rc != EOK) 153 151 goto err; 154 155 vfs_phone = service_connect_blocking(SERVICE_VFS, 0, 0); 156 if (vfs_phone < EOK) { 152 153 async_sess_t *vfs_sess = service_connect_blocking(EXCHANGE_SERIALIZE, 154 SERVICE_VFS, 0, 0); 155 if (!vfs_sess) { 157 156 printf(NAME ": failed to connect to VFS\n"); 158 157 return -1; 159 158 } 160 159 161 rc = fs_register(vfs_ phone, &fat_reg, &fat_vfs_info, fat_connection);160 rc = fs_register(vfs_sess, &fat_reg, &fat_vfs_info, fat_connection); 162 161 if (rc != EOK) { 163 162 fat_idx_fini(); … … 168 167 task_retval(0); 169 168 async_manager(); 170 /* not reached */ 169 170 /* Not reached */ 171 171 return 0; 172 172 173 173 err: 174 174 printf(NAME ": Failed to register file system (%d)\n", rc); … … 178 178 /** 179 179 * @} 180 */ 180 */
Note:
See TracChangeset
for help on using the changeset viewer.