Changeset c028b22 in mainline for uspace/srv/fs/ext2fs/ext2fs.c
- Timestamp:
- 2011-07-08T17:01:01Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- cc1a727
- Parents:
- 4e36219 (diff), 026793d (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/ext2fs/ext2fs.c
r4e36219 rc028b22 40 40 #include "ext2fs.h" 41 41 #include <ipc/services.h> 42 #include < ipc/ns.h>42 #include <ns.h> 43 43 #include <async.h> 44 44 #include <errno.h> … … 75 75 * request has been completed. 76 76 */ 77 static void ext2fs_connection(ipc_callid_t iid, ipc_call_t *icall )77 static void ext2fs_connection(ipc_callid_t iid, ipc_call_t *icall, void *arg) 78 78 { 79 79 if (iid) { … … 87 87 88 88 dprintf(NAME ": connection opened\n"); 89 while (1) { 90 ipc_callid_t callid; 89 while (true) { 91 90 ipc_call_t call; 92 93 callid = async_get_call(&call); 94 switch (IPC_GET_IMETHOD(call)) { 95 case IPC_M_PHONE_HUNGUP: 91 ipc_callid_t callid = async_get_call(&call); 92 93 if (!IPC_GET_IMETHOD(call)) 96 94 return; 95 96 switch (IPC_GET_IMETHOD(call)) { 97 97 case VFS_OUT_MOUNTED: 98 98 ext2fs_mounted(callid, &call); … … 143 143 int main(int argc, char **argv) 144 144 { 145 int vfs_phone;146 int rc;147 148 145 printf(NAME ": HelenOS EXT2 file system server\n"); 149 150 vfs_phone = service_connect_blocking(SERVICE_VFS, 0, 0); 151 if (vfs_phone < EOK) { 146 147 async_sess_t *vfs_sess = service_connect_blocking(EXCHANGE_SERIALIZE, 148 SERVICE_VFS, 0, 0); 149 if (!vfs_sess) { 152 150 printf(NAME ": failed to connect to VFS\n"); 153 151 return -1; 154 152 } 155 153 156 rc = ext2fs_global_init();154 int rc = ext2fs_global_init(); 157 155 if (rc != EOK) { 158 156 printf(NAME ": Failed global initialization\n"); … … 160 158 } 161 159 162 rc = fs_register(vfs_ phone, &ext2fs_reg, &ext2fs_vfs_info, ext2fs_connection);160 rc = fs_register(vfs_sess, &ext2fs_reg, &ext2fs_vfs_info, ext2fs_connection); 163 161 if (rc != EOK) { 164 162 fprintf(stdout, NAME ": Failed to register fs (%d)\n", rc);
Note:
See TracChangeset
for help on using the changeset viewer.