Changes in uspace/lib/drv/generic/driver.c [228e490:0ca16307] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/drv/generic/driver.c
r228e490 r0ca16307 48 48 #include <ctype.h> 49 49 #include <errno.h> 50 #include <inttypes.h>51 50 52 51 #include <ipc/driver.h> … … 81 80 static void driver_irq_handler(ipc_callid_t iid, ipc_call_t *icall) 82 81 { 83 int id = (int)IPC_GET_ IMETHOD(*icall);82 int id = (int)IPC_GET_METHOD(*icall); 84 83 interrupt_context_t *ctx; 85 84 … … 178 177 res = driver->driver_ops->add_device(dev); 179 178 if (0 == res) { 180 printf("%s: new device with handle =%" PRIun "was added.\n",179 printf("%s: new device with handle = %x was added.\n", 181 180 driver->name, dev_handle); 182 181 } else { 183 printf("%s: failed to add a new device with handle = % " PRIun ".\n",182 printf("%s: failed to add a new device with handle = %d.\n", 184 183 driver->name, dev_handle); 185 184 remove_from_devices_list(dev); … … 200 199 ipc_callid_t callid = async_get_call(&call); 201 200 202 switch (IPC_GET_ IMETHOD(call)) {201 switch (IPC_GET_METHOD(call)) { 203 202 case IPC_M_PHONE_HUNGUP: 204 203 cont = false; … … 208 207 break; 209 208 default: 210 ipc_answer_0(callid, ENOENT); 209 if (!(callid & IPC_CALLID_NOTIFICATION)) 210 ipc_answer_0(callid, ENOENT); 211 211 } 212 212 } … … 230 230 if (dev == NULL) { 231 231 printf("%s: driver_connection_gen error - no device with handle" 232 " % " PRIun "was found.\n", driver->name, handle);232 " %x was found.\n", driver->name, handle); 233 233 ipc_answer_0(iid, ENOENT); 234 234 return; … … 254 254 ipc_call_t call; 255 255 callid = async_get_call(&call); 256 sysarg_t method = IPC_GET_IMETHOD(call);256 ipcarg_t method = IPC_GET_METHOD(call); 257 257 int iface_idx; 258 258 … … 294 294 printf("%s: driver_connection_gen error - ", 295 295 driver->name); 296 printf("device with handle % " PRIun "has no interface "296 printf("device with handle %d has no interface " 297 297 "with id %d.\n", handle, iface_idx); 298 298 ipc_answer_0(callid, ENOTSUP); … … 308 308 309 309 /* get the method of the remote interface */ 310 sysarg_t iface_method_idx = IPC_GET_ARG1(call);310 ipcarg_t iface_method_idx = IPC_GET_ARG1(call); 311 311 remote_iface_func_ptr_t iface_method_ptr = 312 312 get_remote_method(rem_iface, iface_method_idx); … … 346 346 { 347 347 /* Select interface */ 348 switch (( sysarg_t) (IPC_GET_ARG1(*icall))) {348 switch ((ipcarg_t) (IPC_GET_ARG1(*icall))) { 349 349 case DRIVER_DEVMAN: 350 350 /* handle PnP events from device manager */ … … 418 418 goto failure; 419 419 420 return EOK;420 goto leave; 421 421 422 422 failure: … … 431 431 } 432 432 433 leave: 433 434 return rc; 434 435 }
Note:
See TracChangeset
for help on using the changeset viewer.