Changeset 8820544 in mainline for uspace/drv/bus
- Timestamp:
- 2014-08-16T00:02:04Z (11 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 35b8bfe, 8cd680c
- Parents:
- 83f29e0
- Location:
- uspace/drv/bus/usb
- Files:
-
- 3 edited
-
ohci/ohci.c (modified) (2 diffs)
-
uhci/hc.c (modified) (2 diffs)
-
uhci/uhci.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/bus/usb/ohci/ohci.c
r83f29e0 r8820544 59 59 /** IRQ handling callback, identifies device 60 60 * 61 * @param[in] dev DDF instance of the device to use.62 61 * @param[in] iid (Unused). 63 62 * @param[in] call Pointer to the call that represents interrupt. 64 */ 65 static void irq_handler(ddf_dev_t *dev, ipc_callid_t iid, ipc_call_t *call) 63 * @param[in] dev DDF instance of the device to use. 64 * 65 */ 66 static void irq_handler(ipc_callid_t iid, ipc_call_t *call, ddf_dev_t *dev) 66 67 { 67 68 assert(dev); 68 69 69 70 ohci_t *ohci = dev_to_ohci(dev); 70 71 if (!ohci) { … … 72 73 return; 73 74 } 75 74 76 const uint16_t status = IPC_GET_ARG1(*call); 75 77 hc_interrupt(&ohci->hc, status); -
uspace/drv/bus/usb/uhci/hc.c
r83f29e0 r8820544 151 151 return rc; 152 152 } 153 153 154 154 irq_code_t irq_code = { 155 155 .rangecount = hc_irq_pio_range_count, … … 158 158 .cmds = irq_cmds 159 159 }; 160 161 /* Register handler to avoid interrupt lockup */162 rc = register_interrupt_handler(device, irq, handler, &irq_code);163 if (rc != EOK) {164 usb_log_error("Failed to register interrupt handler: %s.\n",165 str_error(rc));166 return rc;167 }168 160 161 /* Register handler to avoid interrupt lockup */ 162 rc = register_interrupt_handler(device, irq, handler, &irq_code); 163 if (rc != EOK) { 164 usb_log_error("Failed to register interrupt handler: %s.\n", 165 str_error(rc)); 166 return rc; 167 } 168 169 169 return EOK; 170 170 } -
uspace/drv/bus/usb/uhci/uhci.c
r83f29e0 r8820544 69 69 /** IRQ handling callback, forward status from call to diver structure. 70 70 * 71 * @param[in] dev DDF instance of the device to use.72 71 * @param[in] iid (Unused). 73 72 * @param[in] call Pointer to the call from kernel. 74 */ 75 static void irq_handler(ddf_dev_t *dev, ipc_callid_t iid, ipc_call_t *call) 73 * @param[in] dev DDF instance of the device to use. 74 * 75 */ 76 static void irq_handler(ipc_callid_t iid, ipc_call_t *call, ddf_dev_t *dev) 76 77 { 77 78 assert(dev); 79 78 80 uhci_t *uhci = dev_to_uhci(dev); 79 81 if (!uhci) { … … 81 83 return; 82 84 } 85 83 86 const uint16_t status = IPC_GET_ARG1(*call); 84 87 hc_interrupt(&uhci->hc, status);
Note:
See TracChangeset
for help on using the changeset viewer.
