Changeset aae339e9 in mainline for uspace/lib/drv/generic/remote_usbhc.c
- Timestamp:
- 2010-11-26T12:47:34Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 172c1682
- Parents:
- 0b749a3
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/drv/generic/remote_usbhc.c
r0b749a3 raae339e9 42 42 #define USB_MAX_PAYLOAD_SIZE 1020 43 43 44 static void remote_usbhc_get_address(device_t *, void *, ipc_callid_t, ipc_call_t *); 44 45 static void remote_usbhc_get_buffer(device_t *, void *, ipc_callid_t, ipc_call_t *); 45 46 static void remote_usbhc_interrupt_out(device_t *, void *, ipc_callid_t, ipc_call_t *); … … 49 50 /** Remote USB interface operations. */ 50 51 static remote_iface_func_ptr_t remote_usbhc_iface_ops [] = { 51 &remote_usbhc_get_buffer, 52 &remote_usbhc_interrupt_out, 53 &remote_usbhc_interrupt_in 52 remote_usbhc_get_address, 53 remote_usbhc_get_buffer, 54 remote_usbhc_interrupt_out, 55 remote_usbhc_interrupt_in 54 56 }; 55 57 … … 68 70 } async_transaction_t; 69 71 72 void remote_usbhc_get_address(device_t *device, void *iface, 73 ipc_callid_t callid, ipc_call_t *call) 74 { 75 usbhc_iface_t *usb_iface = (usbhc_iface_t *) iface; 76 77 if (!usb_iface->tell_address) { 78 ipc_answer_0(callid, ENOTSUP); 79 return; 80 } 81 82 devman_handle_t handle = IPC_GET_ARG1(*call); 83 84 usb_address_t address; 85 int rc = usb_iface->tell_address(device, handle, &address); 86 if (rc != EOK) { 87 ipc_answer_0(callid, rc); 88 } else { 89 ipc_answer_1(callid, EOK, address); 90 } 91 } 70 92 71 93 void remote_usbhc_get_buffer(device_t *device, void *iface,
Note:
See TracChangeset
for help on using the changeset viewer.