Changeset 3209923 in mainline for uspace/lib/libc/generic/ipc.c
- Timestamp:
- 2007-11-20T09:12:49Z (18 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- b74959bd
- Parents:
- bc50fc42
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/libc/generic/ipc.c
rbc50fc42 r3209923 190 190 static ipc_callid_t _ipc_call_async(int phoneid, ipc_call_t *data) 191 191 { 192 return __SYSCALL2(SYS_IPC_CALL_ASYNC , phoneid, (sysarg_t) data);192 return __SYSCALL2(SYS_IPC_CALL_ASYNC_SLOW, phoneid, (sysarg_t) data); 193 193 } 194 194 … … 269 269 /** Make a fast asynchronous call. 270 270 * 271 * This function can only handle twoarguments of payload. It is, however,272 * faster than the more generic ipc_call_async_ 3().271 * This function can only handle four arguments of payload. It is, however, 272 * faster than the more generic ipc_call_async_slow(). 273 273 * 274 274 * Note that this function is a void function. … … 281 281 * @param arg1 Service-defined payload argument. 282 282 * @param arg2 Service-defined payload argument. 283 * @param arg3 Service-defined payload argument. 284 * @param arg4 Service-defined payload argument. 283 285 * @param private Argument to be passed to the answer/error callback. 284 286 * @param callback Answer or error callback. … … 287 289 * asynchronous calls. 288 290 */ 289 void ipc_call_async_ 2(int phoneid, ipcarg_t method, ipcarg_t arg1,290 ipcarg_t arg2, void *private, ipc_async_callback_t callback,291 i nt can_preempt)291 void ipc_call_async_fast(int phoneid, ipcarg_t method, ipcarg_t arg1, 292 ipcarg_t arg2, ipcarg_t arg3, ipcarg_t arg4, void *private, 293 ipc_async_callback_t callback, int can_preempt) 292 294 { 293 295 async_call_t *call = NULL; … … 305 307 */ 306 308 futex_down(&ipc_futex); 307 callid = __SYSCALL 4(SYS_IPC_CALL_ASYNC_FAST, phoneid, method, arg1,308 arg2 );309 callid = __SYSCALL6(SYS_IPC_CALL_ASYNC_FAST, phoneid, method, arg1, 310 arg2, arg3, arg4); 309 311 310 312 if (callid == IPC_CALLRET_TEMPORARY) { … … 317 319 IPC_SET_ARG1(call->u.msg.data, arg1); 318 320 IPC_SET_ARG2(call->u.msg.data, arg2); 321 IPC_SET_ARG3(call->u.msg.data, arg3); 322 IPC_SET_ARG4(call->u.msg.data, arg4); 319 323 } 320 324 ipc_finish_async(callid, phoneid, call, can_preempt); … … 333 337 * @param arg2 Service-defined payload argument. 334 338 * @param arg3 Service-defined payload argument. 339 * @param arg4 Service-defined payload argument. 340 * @param arg5 Service-defined payload argument. 335 341 * @param private Argument to be passed to the answer/error callback. 336 342 * @param callback Answer or error callback. … … 340 346 * 341 347 */ 342 void ipc_call_async_ 3(int phoneid, ipcarg_t method, ipcarg_t arg1,343 ipcarg_t arg2, ipcarg_t arg3, void *private, ipc_async_callback_t callback,344 i nt can_preempt)348 void ipc_call_async_slow(int phoneid, ipcarg_t method, ipcarg_t arg1, 349 ipcarg_t arg2, ipcarg_t arg3, ipcarg_t arg4, ipcarg_t arg5, void *private, 350 ipc_async_callback_t callback, int can_preempt) 345 351 { 346 352 async_call_t *call; … … 355 361 IPC_SET_ARG2(call->u.msg.data, arg2); 356 362 IPC_SET_ARG3(call->u.msg.data, arg3); 363 IPC_SET_ARG4(call->u.msg.data, arg4); 364 IPC_SET_ARG5(call->u.msg.data, arg5); 357 365 /* 358 * We need to make sure that we get callid before another thread accesses359 * the queue again.366 * We need to make sure that we get callid before another thread 367 * accesses the queue again. 360 368 */ 361 369 futex_down(&ipc_futex);
Note:
See TracChangeset
for help on using the changeset viewer.