From: Thomas Gleixner <tglx@linutronix.de>
To: LKML <linux-kernel@vger.kernel.org>
Cc: Linus Torvalds <torvalds@osdl.org>,
Andrew Morton <akpm@linux-foundation.org>,
Ingo Molnar <mingo@elte.hu>,
Arjan van de Veen <arjan@infradead.org>,
Benjamin Herrenschmidt <benh@kernel.crashing.org>,
Steven Rostedt <rostedt@goodmis.org>,
Jon Masters <jonathan@jonmasters.org>,
Sven Dietrich <sdietrich@suse.de>
Subject: [RFC patch 1/5] genirq: make irqreturn_t an enum
Date: Wed, 01 Oct 2008 23:02:14 -0000 [thread overview]
Message-ID: <20081001223301.787166666@linutronix.de> (raw)
In-Reply-To: <20081001223213.078984344@linutronix.de>
[-- Attachment #1: genirq-makeirq-return-t-an-enum.patch --]
[-- Type: text/plain, Size: 2220 bytes --]
Remove the 2.4 compabiliy cruft
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Ingo Molnar <mingo@elte.hu>
---
include/linux/irq.h | 4 ++--
include/linux/irqreturn.h | 28 ++++++++++------------------
2 files changed, 12 insertions(+), 20 deletions(-)
Index: linux-2.6-tip/include/linux/irq.h
===================================================================
--- linux-2.6-tip.orig/include/linux/irq.h
+++ linux-2.6-tip/include/linux/irq.h
@@ -252,7 +252,7 @@ static inline int irq_balancing_disabled
}
/* Handle irq action chains: */
-extern int handle_IRQ_event(unsigned int irq, struct irqaction *action);
+extern irqreturn_t handle_IRQ_event(unsigned int irq, struct irqaction *action);
/*
* Built-in IRQ handlers for various IRQ types,
@@ -294,7 +294,7 @@ static inline void generic_handle_irq(un
/* Handling of unhandled and spurious interrupts: */
extern void note_interrupt(unsigned int irq, struct irq_desc *desc,
- int action_ret);
+ irqreturn_t action_ret);
/* Resending of interrupts :*/
void check_irq_resend(struct irq_desc *desc, unsigned int irq);
Index: linux-2.6-tip/include/linux/irqreturn.h
===================================================================
--- linux-2.6-tip.orig/include/linux/irqreturn.h
+++ linux-2.6-tip/include/linux/irqreturn.h
@@ -1,25 +1,17 @@
-/* irqreturn.h */
#ifndef _LINUX_IRQRETURN_H
#define _LINUX_IRQRETURN_H
-/*
- * For 2.4.x compatibility, 2.4.x can use
- *
- * typedef void irqreturn_t;
- * #define IRQ_NONE
- * #define IRQ_HANDLED
- * #define IRQ_RETVAL(x)
- *
- * To mix old-style and new-style irq handler returns.
- *
- * IRQ_NONE means we didn't handle it.
- * IRQ_HANDLED means that we did have a valid interrupt and handled it.
- * IRQ_RETVAL(x) selects on the two depending on x being non-zero (for handled)
+/**
+ * enum irqreturn
+ * @IRQ_NONE interrupt was not from this device
+ * @IRQ_HANDLED interrupt was handled by this device
*/
-typedef int irqreturn_t;
+enum irqreturn {
+ IRQ_NONE,
+ IRQ_HANDLED,
+};
-#define IRQ_NONE (0)
-#define IRQ_HANDLED (1)
-#define IRQ_RETVAL(x) ((x) != 0)
+#define irqreturn_t enum irqreturn
+#define IRQ_RETVAL(x) ((x) != IRQ_NONE)
#endif
next prev parent reply other threads:[~2008-10-01 23:04 UTC|newest]
Thread overview: 49+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-01 23:02 [RFC patch 0/5] genirq: add infrastructure for threaded interrupt handlers Thomas Gleixner
2008-10-01 23:02 ` Thomas Gleixner [this message]
2008-10-01 23:02 ` [RFC patch 2/5] genirq: add a quick check handler Thomas Gleixner
2008-10-02 0:47 ` Jon Masters
2008-10-02 5:09 ` Steven Rostedt
2008-10-02 10:51 ` Jon Masters
2008-10-02 22:06 ` Greg KH
2008-10-02 4:52 ` Steven Rostedt
2008-10-03 8:29 ` Christoph Hellwig
2008-10-03 10:37 ` Thomas Gleixner
2008-10-01 23:02 ` [RFC patch 3/5] genirq: add threaded interrupt handler support Thomas Gleixner
2008-10-02 5:01 ` Steven Rostedt
2008-10-01 23:02 ` [RFC patch 4/5] genirq: add a helper to check whether the irq thread should run Thomas Gleixner
2008-10-01 23:02 ` [RFC patch 5/5] genirq: make irq threading robust Thomas Gleixner
2008-10-02 0:52 ` Jon Masters
2008-10-02 5:20 ` Steven Rostedt
2008-10-01 23:23 ` [RFC patch 0/5] genirq: add infrastructure for threaded interrupt handlers Andrew Morton
2008-10-01 23:29 ` Arjan van de Ven
2008-10-01 23:40 ` Andrew Morton
2008-10-01 23:58 ` Thomas Gleixner
2008-10-02 0:40 ` Jon Masters
2008-10-02 22:07 ` Greg KH
2008-10-08 22:18 ` Ingo Oeser
2008-10-02 1:53 ` Daniel Walker
2008-10-02 15:02 ` Steven Rostedt
2008-10-02 15:48 ` Daniel Walker
2008-10-02 18:42 ` Thomas Gleixner
2008-10-02 19:04 ` Daniel Walker
2008-10-02 19:23 ` Steven Rostedt
2008-10-02 19:28 ` Ingo Molnar
2008-10-02 20:09 ` Daniel Walker
2008-10-02 20:14 ` Steven Rostedt
2008-10-02 20:48 ` Daniel Walker
2008-10-02 21:05 ` Steven Rostedt
2008-10-02 21:30 ` Daniel Walker
2008-10-02 22:28 ` Steven Rostedt
2008-10-02 23:24 ` Daniel Walker
2008-10-03 0:26 ` Thomas Gleixner
2008-10-03 14:44 ` Daniel Walker
2008-10-02 14:46 ` Andi Kleen
2008-10-02 21:31 ` Greg KH
2008-10-02 22:33 ` Arjan van de Ven
2008-10-03 3:25 ` Andi Kleen
2008-10-03 3:48 ` Arjan van de Ven
2008-10-03 4:35 ` Andi Kleen
2008-10-03 3:23 ` Andi Kleen
2008-10-21 1:32 ` [RFC patch] genirq threading for ehci, ohci and uhci USB hosts Sven-Thorsten Dietrich
2008-10-21 2:07 ` Jonathan Woithe
2008-10-21 10:29 ` [RFC patch] genirq threading (v2) for ehci, ohci and uhci USB hosts and ohci1394 Sven-Thorsten Dietrich
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20081001223301.787166666@linutronix.de \
--to=tglx@linutronix.de \
--cc=akpm@linux-foundation.org \
--cc=arjan@infradead.org \
--cc=benh@kernel.crashing.org \
--cc=jonathan@jonmasters.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=rostedt@goodmis.org \
--cc=sdietrich@suse.de \
--cc=torvalds@osdl.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®