/*-------------------------------------------------------------------------*/
/* GPIO interrupt handlers */
-static irq_handler_t
-DIO0_irq_handler(unsigned int irq, void *dev_id, struct pt_regs *regs)
+static irqreturn_t DIO0_irq_handler(int irq, void *dev_id)
{
struct pi433_device *device = dev_id;
wake_up_interruptible(&device->fifo_wait_queue);
}
- return (irq_handler_t) IRQ_HANDLED;
+ return IRQ_HANDLED;
}
-static irq_handler_t
-DIO1_irq_handler(unsigned int irq, void *dev_id, struct pt_regs *regs)
+static irqreturn_t DIO1_irq_handler(int irq, void *dev_id)
{
struct pi433_device *device = dev_id;
printk("DIO1 irq: %d bytes free in fifo\n", device->free_in_fifo); // TODO: printk() should include KERN_ facility level
wake_up_interruptible(&device->fifo_wait_queue);
- return (irq_handler_t) IRQ_HANDLED;
+ return IRQ_HANDLED;
}
-static void *DIO_irq_handler[NUM_DIO] = {
- DIO0_irq_handler,
- DIO1_irq_handler
-};
-
/*-------------------------------------------------------------------------*/
static int
char name[5];
int retval;
int i;
+ const irq_handler_t DIO_irq_handler[NUM_DIO] = {
+ DIO0_irq_handler,
+ DIO1_irq_handler
+ };
for (i=0; i<NUM_DIO; i++)
{