Changeset 7b2a7ad in mainline
- Timestamp:
- 2011-08-19T18:08:04Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 58cbf8d5
- Parents:
- b76a7329 (diff), ab34cc9 (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. - Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
abi/include/ipc/methods.h
rb76a7329 r7b2a7ad 96 96 * error is sent back to caller. Otherwise 97 97 * the call is accepted and the response is sent back. 98 * - the hash of the client task is passed to userspace99 * (on the receiving side) as ARG4 of the call.100 98 * - the hash of the allocated phone is passed to userspace 101 99 * (on the receiving side) as ARG5 of the call. -
kernel/generic/include/ipc/ipc.h
rb76a7329 r7b2a7ad 98 98 typedef struct { 99 99 sysarg_t args[IPC_CALL_LEN]; 100 /** Task which made or forwarded the call with IPC_FF_ROUTE_FROM_ME. */ 100 /** 101 * Task which made or forwarded the call with IPC_FF_ROUTE_FROM_ME, 102 * or the task which answered the call. 103 */ 101 104 task_id_t task_id; 102 105 /** Phone which made or last masqueraded this call. */ -
kernel/generic/src/ipc/ipc.c
rb76a7329 r7b2a7ad 230 230 } 231 231 } 232 233 call->data.task_id = TASK->taskid; 232 234 233 235 if (do_lock) -
kernel/generic/src/ipc/sysipc.c
rb76a7329 r7b2a7ad 253 253 /* The connection was accepted */ 254 254 phone_connect(phoneid, &answer->sender->answerbox); 255 /* Set 'task ID' as arg3 and arg4 of response */256 IPC_SET_ARG3(answer->data, LOWER32(TASK->taskid));257 IPC_SET_ARG4(answer->data, UPPER32(TASK->taskid));258 255 /* Set 'phone hash' as arg5 of response */ 259 256 IPC_SET_ARG5(answer->data, -
uspace/lib/c/generic/async.c
rb76a7329 r7b2a7ad 1472 1472 return ENOENT; 1473 1473 1474 task_id_t task_id;1475 sysarg_t task_id_lo;1476 sysarg_t task_id_hi;1477 1474 sysarg_t phone_hash; 1478 int rc = async_req_3_5(exch, IPC_M_CONNECT_TO_ME, arg1, arg2, arg3, 1479 NULL, NULL, &task_id_lo, &task_id_hi, &phone_hash); 1475 sysarg_t rc; 1476 1477 aid_t req; 1478 ipc_call_t answer; 1479 req = async_send_3(exch, IPC_M_CONNECT_TO_ME, arg1, arg2, arg3, 1480 &answer); 1481 async_wait_for(req, &rc); 1480 1482 if (rc != EOK) 1481 return rc;1482 1483 task_id = (task_id_t) MERGE_LOUP32(task_id_lo, task_id_hi);1484 1483 return (int) rc; 1484 1485 phone_hash = IPC_GET_ARG5(answer); 1486 1485 1487 if (client_receiver != NULL) 1486 async_new_connection( task_id, phone_hash, 0, NULL,1488 async_new_connection(answer.in_task_id, phone_hash, 0, NULL, 1487 1489 client_receiver, carg); 1488 1490 -
uspace/lib/c/generic/ipc.c
rb76a7329 r7b2a7ad 47 47 #include <futex.h> 48 48 #include <fibril.h> 49 #include <macros.h> 49 50 50 51 /** … … 611 612 /** Request callback connection. 612 613 * 613 * The @a task hashand @a phonehash identifiers returned614 * The @a task_id and @a phonehash identifiers returned 614 615 * by the kernel can be used for connection tracking. 615 616 * … … 618 619 * @param arg2 User defined argument. 619 620 * @param arg3 User defined argument. 620 * @param task hash Opaque identifier of the client task.621 * @param task_id Identifier of the client task. 621 622 * @param phonehash Opaque identifier of the phone that will 622 623 * be used for incoming calls. … … 626 627 */ 627 628 int ipc_connect_to_me(int phoneid, sysarg_t arg1, sysarg_t arg2, sysarg_t arg3, 628 sysarg_t *taskhash, sysarg_t *phonehash) 629 { 630 return ipc_call_sync_3_5(phoneid, IPC_M_CONNECT_TO_ME, arg1, arg2, 631 arg3, NULL, NULL, NULL, taskhash, phonehash); 629 task_id_t *task_id, sysarg_t *phonehash) 630 { 631 ipc_call_t data; 632 int rc = __SYSCALL6(SYS_IPC_CALL_SYNC_FAST, phoneid, 633 IPC_M_CONNECT_TO_ME, arg1, arg2, arg3, (sysarg_t) &data); 634 if (rc == EOK) { 635 *task_id = data.in_task_id; 636 *phonehash = IPC_GET_ARG5(data); 637 } 638 return rc; 632 639 } 633 640 -
uspace/lib/c/include/ipc/ipc.h
rb76a7329 r7b2a7ad 254 254 sysarg_t, sysarg_t, void *, ipc_async_callback_t, bool); 255 255 256 extern int ipc_connect_to_me(int, sysarg_t, sysarg_t, sysarg_t, sysarg_t *,256 extern int ipc_connect_to_me(int, sysarg_t, sysarg_t, sysarg_t, task_id_t *, 257 257 sysarg_t *); 258 258 extern int ipc_connect_me(int);
Note:
See TracChangeset
for help on using the changeset viewer.