Changeset 60744cb in mainline for uspace/lib
- Timestamp:
- 2024-05-17T17:51:56Z (17 months ago)
- Branches:
- master
- Children:
- 1801005
- Parents:
- 646849b3
- Location:
- uspace/lib
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/drv/generic/interrupt.c
r646849b3 r60744cb 44 44 45 45 errno_t register_interrupt_handler(ddf_dev_t *dev, int irq, 46 interrupt_handler_t *handler, const irq_code_t *irq_code,47 cap_irq_handle_t *handle)48 {49 return async_irq_subscribe(irq, (async_notification_handler_t) handler,50 dev, irq_code, handle);51 }52 53 errno_t register_interrupt_handler_arg(ddf_dev_t *dev, int irq,54 46 interrupt_handler_t *handler, void *arg, const irq_code_t *irq_code, 55 47 cap_irq_handle_t *handle) -
uspace/lib/drv/include/ddf/interrupt.h
r646849b3 r60744cb 49 49 */ 50 50 51 typedef void interrupt_handler_t(ipc_call_t *, ddf_dev_t*);51 typedef void interrupt_handler_t(ipc_call_t *, void *); 52 52 53 extern errno_t register_interrupt_handler(ddf_dev_t *, int, interrupt_handler_t *, 54 const irq_code_t *, cap_irq_handle_t *); 55 extern errno_t register_interrupt_handler_arg(ddf_dev_t *, int, 53 extern errno_t register_interrupt_handler(ddf_dev_t *, int, 56 54 interrupt_handler_t *, void *, const irq_code_t *, cap_irq_handle_t *); 57 55 extern errno_t unregister_interrupt_handler(ddf_dev_t *, cap_irq_handle_t); -
uspace/lib/usbhost/src/hcd.c
r646849b3 r60744cb 95 95 * TODO: Make the bus mechanism less flexible in irq handling and remove the 96 96 * lookup. 97 */ 98 static void irq_handler(ipc_call_t *call, ddf_dev_t *dev) 99 { 100 assert(dev); 101 hc_device_t *hcd = dev_to_hcd(dev); 97 * 98 * @param call Interrupt notification 99 * @param arg Argument (hc_device_t *) 100 */ 101 static void irq_handler(ipc_call_t *call, void *arg) 102 { 103 hc_device_t *hcd = (hc_device_t *)arg; 102 104 103 105 const uint32_t status = ipc_get_arg1(call); … … 178 180 cap_irq_handle_t ihandle; 179 181 ret = register_interrupt_handler(hcd->ddf_dev, irq, irq_handler, 180 &irq_code, &ihandle);182 (void *)hcd, &irq_code, &ihandle); 181 183 irq_code_clean(&irq_code); 182 184 if (ret != EOK) {
Note:
See TracChangeset
for help on using the changeset viewer.