Changeset 3c22f70 in mainline
- Timestamp:
- 2011-01-24T00:14:13Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 8c9b742
- Parents:
- 11bb813
- Location:
- uspace
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/async.c
r11bb813 r3c22f70 139 139 link_t link; 140 140 141 /** Incoming client task hash. */ 142 sysarg_t in_task_hash; 141 143 /** Incoming phone hash. */ 142 144 sysarg_t in_phone_hash; … … 517 519 * particular fibrils. 518 520 * 521 * @param in_task_hash Identification of the incoming connection. 519 522 * @param in_phone_hash Identification of the incoming connection. 520 523 * @param callid Hash of the opening IPC_M_CONNECT_ME_TO call. … … 529 532 * 530 533 */ 531 fid_t async_new_connection(sysarg_t in_phone_hash, ipc_callid_t callid, 532 ipc_call_t *call, void (*cfibril)(ipc_callid_t, ipc_call_t *)) 534 fid_t async_new_connection(sysarg_t in_task_hash, sysarg_t in_phone_hash, 535 ipc_callid_t callid, ipc_call_t *call, 536 void (*cfibril)(ipc_callid_t, ipc_call_t *)) 533 537 { 534 538 connection_t *conn = malloc(sizeof(*conn)); … … 539 543 } 540 544 545 conn->in_task_hash = in_task_hash; 541 546 conn->in_phone_hash = in_phone_hash; 542 547 list_initialize(&conn->msg_queue); … … 592 597 case IPC_M_CONNECT_ME_TO: 593 598 /* Open new connection with fibril etc. */ 594 async_new_connection( IPC_GET_ARG5(*call), callid, call,595 c lient_connection);599 async_new_connection(call->in_task_hash, IPC_GET_ARG5(*call), 600 callid, call, client_connection); 596 601 goto out; 597 602 } -
uspace/lib/c/generic/net/modules.c
r11bb813 r3c22f70 143 143 if (phone >= 0) { 144 144 /* Request the bidirectional connection */ 145 sysarg_t taskhash; 145 146 sysarg_t phonehash; 146 147 147 rc = ipc_connect_to_me(phone, arg1, arg2, arg3, NULL,148 rc = ipc_connect_to_me(phone, arg1, arg2, arg3, &taskhash, 148 149 &phonehash); 149 150 if (rc != EOK) { … … 151 152 return rc; 152 153 } 153 async_new_connection(phonehash, 0, NULL, client_receiver); 154 async_new_connection(taskhash, phonehash, 0, NULL, 155 client_receiver); 154 156 } 155 157 -
uspace/lib/c/include/async.h
r11bb813 r3c22f70 92 92 extern int async_wait_timeout(aid_t, sysarg_t *, suseconds_t); 93 93 94 extern fid_t async_new_connection(sysarg_t, ipc_callid_t, ipc_call_t *,95 void (*)(ipc_callid_t, ipc_call_t *));94 extern fid_t async_new_connection(sysarg_t, sysarg_t, ipc_callid_t, 95 ipc_call_t *, void (*)(ipc_callid_t, ipc_call_t *)); 96 96 extern void async_usleep(suseconds_t); 97 97 extern void async_create_manager(void); -
uspace/lib/c/include/ipc/ipc.h
r11bb813 r3c22f70 46 46 typedef struct { 47 47 sysarg_t args[IPC_CALL_LEN]; 48 sysarg_t in_task_hash; 48 49 sysarg_t in_phone_hash; 49 sysarg_t in_task_hash;50 50 } ipc_call_t; 51 51 -
uspace/lib/fs/libfs.c
r11bb813 r3c22f70 102 102 * Ask VFS for callback connection. 103 103 */ 104 ipc_connect_to_me(vfs_phone, 0, 0, 0, NULL, ®->vfs_phonehash); 104 sysarg_t taskhash; 105 ipc_connect_to_me(vfs_phone, 0, 0, 0, &taskhash, ®->vfs_phonehash); 105 106 106 107 /* … … 131 132 * Create a connection fibril to handle the callback connection. 132 133 */ 133 async_new_connection( reg->vfs_phonehash, 0, NULL, conn);134 async_new_connection(taskhash, reg->vfs_phonehash, 0, NULL, conn); 134 135 135 136 /* -
uspace/srv/hid/adb_mouse/adb_dev.c
r11bb813 r3c22f70 68 68 69 69 /* NB: The callback connection is slotted for removal */ 70 sysarg_t taskhash; 70 71 sysarg_t phonehash; 71 if (ipc_connect_to_me(dev_phone, 0, 0, 0, NULL, &phonehash) != 0) {72 if (ipc_connect_to_me(dev_phone, 0, 0, 0, &taskhash, &phonehash) != 0) { 72 73 printf(NAME ": Failed to create callback from device\n"); 73 74 return false; 74 75 } 75 76 76 async_new_connection( phonehash, 0, NULL, adb_dev_events);77 async_new_connection(taskhash, phonehash, 0, NULL, adb_dev_events); 77 78 78 79 return 0; -
uspace/srv/hid/char_mouse/chardev.c
r11bb813 r3c22f70 70 70 71 71 /* NB: The callback connection is slotted for removal */ 72 sysarg_t taskhash; 72 73 sysarg_t phonehash; 73 if (ipc_connect_to_me(dev_phone, 0, 0, 0, NULL, &phonehash) != 0) {74 if (ipc_connect_to_me(dev_phone, 0, 0, 0, &taskhash, &phonehash) != 0) { 74 75 printf(NAME ": Failed to create callback from device\n"); 75 76 return false; 76 77 } 77 78 78 async_new_connection( phonehash, 0, NULL, chardev_events);79 async_new_connection(taskhash, phonehash, 0, NULL, chardev_events); 79 80 80 81 return 0; -
uspace/srv/hid/console/console.c
r11bb813 r3c22f70 726 726 727 727 /* NB: The callback connection is slotted for removal */ 728 sysarg_t taskhash; 728 729 sysarg_t phonehash; 729 if (ipc_connect_to_me(kbd_phone, SERVICE_CONSOLE, 0, 0, NULL,730 if (ipc_connect_to_me(kbd_phone, SERVICE_CONSOLE, 0, 0, &taskhash, 730 731 &phonehash) != 0) { 731 732 printf(NAME ": Failed to create callback from input device\n"); … … 733 734 } 734 735 735 async_new_connection( phonehash, 0, NULL, keyboard_events);736 async_new_connection(taskhash, phonehash, 0, NULL, keyboard_events); 736 737 737 738 /* Connect to mouse device */ … … 750 751 } 751 752 752 if (ipc_connect_to_me(mouse_phone, SERVICE_CONSOLE, 0, 0, NULL,753 if (ipc_connect_to_me(mouse_phone, SERVICE_CONSOLE, 0, 0, &taskhash, 753 754 &phonehash) != 0) { 754 755 printf(NAME ": Failed to create callback from mouse device\n"); … … 757 758 } 758 759 759 async_new_connection( phonehash, 0, NULL, mouse_events);760 async_new_connection(taskhash, phonehash, 0, NULL, mouse_events); 760 761 skip_mouse: 761 762 -
uspace/srv/hid/kbd/port/adb.c
r11bb813 r3c22f70 71 71 72 72 /* NB: The callback connection is slotted for removal */ 73 sysarg_t taskhash; 73 74 sysarg_t phonehash; 74 if (ipc_connect_to_me(dev_phone, 0, 0, 0, NULL, &phonehash) != 0) {75 if (ipc_connect_to_me(dev_phone, 0, 0, 0, &taskhash, &phonehash) != 0) { 75 76 printf(NAME ": Failed to create callback from device\n"); 76 77 return false; 77 78 } 78 79 79 async_new_connection( phonehash, 0, NULL, kbd_port_events);80 async_new_connection(taskhash, phonehash, 0, NULL, kbd_port_events); 80 81 81 82 return 0; -
uspace/srv/hid/kbd/port/chardev.c
r11bb813 r3c22f70 91 91 92 92 /* NB: The callback connection is slotted for removal */ 93 sysarg_t taskhash; 93 94 sysarg_t phonehash; 94 if (ipc_connect_to_me(dev_phone, 0, 0, 0, NULL, &phonehash) != 0) {95 if (ipc_connect_to_me(dev_phone, 0, 0, 0, &taskhash, &phonehash) != 0) { 95 96 printf(NAME ": Failed to create callback from device\n"); 96 97 return -1; 97 98 } 98 99 99 async_new_connection( phonehash, 0, NULL, kbd_port_events);100 async_new_connection(taskhash, phonehash, 0, NULL, kbd_port_events); 100 101 101 102 return 0;
Note:
See TracChangeset
for help on using the changeset viewer.