Changeset 984a9ba in mainline for uspace/drv/hid/adb-kbd/adb-kbd.c
- Timestamp:
- 2018-07-05T09:34:09Z (6 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 63d46341
- Parents:
- 76f566d
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/hid/adb-kbd/adb-kbd.c
r76f566d r984a9ba 43 43 #include "ctl.h" 44 44 45 static void adb_kbd_events( cap_call_handle_t,ipc_call_t *, void *);45 static void adb_kbd_events(ipc_call_t *, void *); 46 46 static void adb_kbd_reg0_data(adb_kbd_t *, uint16_t); 47 static void adb_kbd_conn( cap_call_handle_t,ipc_call_t *, void *);47 static void adb_kbd_conn(ipc_call_t *, void *); 48 48 49 49 /** Add ADB keyboard device */ … … 130 130 } 131 131 132 static void adb_kbd_events( cap_call_handle_t icall_handle,ipc_call_t *icall, void *arg)132 static void adb_kbd_events(ipc_call_t *icall, void *arg) 133 133 { 134 134 adb_kbd_t *kbd = (adb_kbd_t *) arg; … … 136 136 /* Ignore parameters, the connection is already opened */ 137 137 while (true) { 138 139 138 ipc_call_t call; 140 cap_call_handle_t chandle =async_get_call(&call);139 async_get_call(&call); 141 140 142 141 errno_t retval = EOK; … … 154 153 retval = ENOENT; 155 154 } 156 async_answer_0( chandle, retval);155 async_answer_0(&call, retval); 157 156 } 158 157 } … … 191 190 192 191 /** Handle client connection */ 193 static void adb_kbd_conn(cap_call_handle_t icall_handle, ipc_call_t *icall, void *arg) 194 { 195 cap_call_handle_t chandle; 192 static void adb_kbd_conn(ipc_call_t *icall, void *arg) 193 { 196 194 ipc_call_t call; 197 195 sysarg_t method; … … 201 199 * Answer the first IPC_M_CONNECT_ME_TO call. 202 200 */ 203 async_answer_0(icall _handle, EOK);201 async_answer_0(icall, EOK); 204 202 205 203 kbd = (adb_kbd_t *)ddf_dev_data_get(ddf_fun_get_dev((ddf_fun_t *)arg)); 206 204 207 205 while (true) { 208 chandle =async_get_call(&call);206 async_get_call(&call); 209 207 method = IPC_GET_IMETHOD(call); 210 208 211 209 if (!method) { 212 210 /* The other side has hung up. */ 213 async_answer_0( chandle, EOK);211 async_answer_0(&call, EOK); 214 212 return; 215 213 } … … 219 217 if (sess != NULL) { 220 218 kbd->client_sess = sess; 221 async_answer_0( chandle, EOK);219 async_answer_0(&call, EOK); 222 220 } else { 223 async_answer_0( chandle, EINVAL);221 async_answer_0(&call, EINVAL); 224 222 } 225 223 }
Note:
See TracChangeset
for help on using the changeset viewer.