[patch 5/5] [PREEMPT_RT] Changing interrupt handlers from runningin thread to hardirq and back runtime.

From: Esben Nielsen
Date: Fri Jun 02 2006 - 17:22:50 EST


Make lpptest more compliant with the request_irq() interface. I don't think
the driver should set or remove flags on it's own!

Index: linux-2.6.16-rt23.spin_mutex/drivers/char/lpptest.c
===================================================================
--- linux-2.6.16-rt23.spin_mutex.orig/drivers/char/lpptest.c
+++ linux-2.6.16-rt23.spin_mutex/drivers/char/lpptest.c
@@ -150,13 +150,13 @@ static int __init lpptest_init (void)
return -EAGAIN;
}

- if (request_irq (LPPTEST_IRQ, lpptest_irq, 0, "lpptest", dev_id)) {
- printk (KERN_WARNING "lpptest: irq %d in use. Unload parport module!\n", LPPTEST_IRQ);
+ if (request_irq (LPPTEST_IRQ, lpptest_irq, SA_NODELAY | SA_INTERRUPT,
+ "lpptest", dev_id)) {
+ printk (KERN_WARNING "lpptest: irq %d in use. "
+ "Unload parport module!\n", LPPTEST_IRQ);
unregister_chrdev(LPPTEST_CHAR_MAJOR, LPPTEST_DEVICE_NAME);
return -EAGAIN;
}
- irq_desc[LPPTEST_IRQ].status |= IRQ_NODELAY;
- irq_desc[LPPTEST_IRQ].action->flags |= SA_NODELAY | SA_INTERRUPT;

INIT_PORT();
ENABLE_IRQ();

--
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/