Rev 4537 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 4537 | Rev 4668 | ||
---|---|---|---|
Line 94... | Line 94... | ||
94 | ipc_callid_t callid; |
94 | ipc_callid_t callid; |
95 | ipc_call_t call; |
95 | ipc_call_t call; |
96 | 96 | ||
97 | callid = async_get_call(&call); |
97 | callid = async_get_call(&call); |
98 | switch (IPC_GET_METHOD(call)) { |
98 | switch (IPC_GET_METHOD(call)) { |
- | 99 | case IPC_M_PHONE_HUNGUP: |
|
- | 100 | return; |
|
99 | case VFS_MOUNTED: |
101 | case VFS_OUT_MOUNTED: |
100 | tmpfs_mounted(callid, &call); |
102 | tmpfs_mounted(callid, &call); |
101 | break; |
103 | break; |
102 | case VFS_MOUNT: |
104 | case VFS_OUT_MOUNT: |
103 | tmpfs_mount(callid, &call); |
105 | tmpfs_mount(callid, &call); |
104 | break; |
106 | break; |
105 | case VFS_LOOKUP: |
107 | case VFS_OUT_LOOKUP: |
106 | tmpfs_lookup(callid, &call); |
108 | tmpfs_lookup(callid, &call); |
107 | break; |
109 | break; |
108 | case VFS_READ: |
110 | case VFS_OUT_READ: |
109 | tmpfs_read(callid, &call); |
111 | tmpfs_read(callid, &call); |
110 | break; |
112 | break; |
111 | case VFS_WRITE: |
113 | case VFS_OUT_WRITE: |
112 | tmpfs_write(callid, &call); |
114 | tmpfs_write(callid, &call); |
113 | break; |
115 | break; |
114 | case VFS_TRUNCATE: |
116 | case VFS_OUT_TRUNCATE: |
115 | tmpfs_truncate(callid, &call); |
117 | tmpfs_truncate(callid, &call); |
116 | break; |
118 | break; |
117 | case VFS_CLOSE: |
119 | case VFS_OUT_CLOSE: |
118 | tmpfs_close(callid, &call); |
120 | tmpfs_close(callid, &call); |
119 | break; |
121 | break; |
120 | case VFS_DESTROY: |
122 | case VFS_OUT_DESTROY: |
121 | tmpfs_destroy(callid, &call); |
123 | tmpfs_destroy(callid, &call); |
122 | break; |
124 | break; |
123 | case VFS_OPEN_NODE: |
125 | case VFS_OUT_OPEN_NODE: |
124 | tmpfs_open_node(callid, &call); |
126 | tmpfs_open_node(callid, &call); |
125 | break; |
127 | break; |
126 | case VFS_DEVICE: |
128 | case VFS_OUT_STAT: |
127 | tmpfs_device(callid, &call); |
129 | tmpfs_stat(callid, &call); |
128 | break; |
130 | break; |
129 | case VFS_SYNC: |
131 | case VFS_OUT_SYNC: |
130 | tmpfs_sync(callid, &call); |
132 | tmpfs_sync(callid, &call); |
131 | break; |
133 | break; |
132 | default: |
134 | default: |
133 | ipc_answer_0(callid, ENOTSUP); |
135 | ipc_answer_0(callid, ENOTSUP); |
134 | break; |
136 | break; |
Line 148... | Line 150... | ||
148 | int vfs_phone = ipc_connect_me_to_blocking(PHONE_NS, SERVICE_VFS, 0, 0); |
150 | int vfs_phone = ipc_connect_me_to_blocking(PHONE_NS, SERVICE_VFS, 0, 0); |
149 | if (vfs_phone < EOK) { |
151 | if (vfs_phone < EOK) { |
150 | printf(NAME ": Unable to connect to VFS\n"); |
152 | printf(NAME ": Unable to connect to VFS\n"); |
151 | return -1; |
153 | return -1; |
152 | } |
154 | } |
153 | 155 | ||
154 | int rc = fs_register(vfs_phone, &tmpfs_reg, &tmpfs_vfs_info, |
156 | int rc = fs_register(vfs_phone, &tmpfs_reg, &tmpfs_vfs_info, |
155 | tmpfs_connection); |
157 | tmpfs_connection); |
156 | if (rc != EOK) { |
158 | if (rc != EOK) { |
157 | printf(NAME ": Failed to register file system (%d)\n", rc); |
159 | printf(NAME ": Failed to register file system (%d)\n", rc); |
158 | return rc; |
160 | return rc; |