[PATCH] Convert Alpha to the new 2.5 IRQ API

Marc Zyngier (mzyngier@freesurf.fr)
21 Apr 2003 17:08:06 +0200


Richard, Linus,

This patch converts the Alpha architecture to the new 2.5 IRQ API.
Tested on Jensen.

Thanks,

M.

# This is a BitKeeper generated patch for the following project:
# Project Name: Linux kernel tree
# This patch format is intended for GNU patch command version 2.5 or higher.
# This patch includes the following deltas:
# ChangeSet 1.1121 -> 1.1122
# arch/alpha/kernel/proto.h 1.14 -> 1.15
# arch/alpha/kernel/time.c 1.16 -> 1.17
# arch/alpha/kernel/irq.c 1.19 -> 1.20
#
# The following is the BitKeeper ChangeSet Log
# --------------------------------------------
# 03/04/21 maz@hina.wild-wind.fr.eu.org 1.1122
# Convert Alpha to the new IRQ API.
# --------------------------------------------
#
diff -Nru a/arch/alpha/kernel/irq.c b/arch/alpha/kernel/irq.c
--- a/arch/alpha/kernel/irq.c Mon Apr 21 17:00:46 2003
+++ b/arch/alpha/kernel/irq.c Mon Apr 21 17:00:46 2003
@@ -45,7 +45,10 @@
* Special irq handlers.
*/

-void no_action(int cpl, void *dev_id, struct pt_regs *regs) { }
+irqreturn_t no_action(int cpl, void *dev_id, struct pt_regs *regs)
+{
+ return IRQ_NONE;
+}

/*
* Generic no controller code
@@ -414,7 +417,7 @@
}

int
-request_irq(unsigned int irq, void (*handler)(int, void *, struct pt_regs *),
+request_irq(unsigned int irq, irqreturn_t (*handler)(int, void *, struct pt_regs *),
unsigned long irqflags, const char * devname, void *dev_id)
{
int retval;
diff -Nru a/arch/alpha/kernel/proto.h b/arch/alpha/kernel/proto.h
--- a/arch/alpha/kernel/proto.h Mon Apr 21 17:00:46 2003
+++ b/arch/alpha/kernel/proto.h Mon Apr 21 17:00:46 2003
@@ -1,4 +1,5 @@
#include <linux/config.h>
+#include <linux/interrupt.h>


/* Prototypes of functions used across modules here in this directory. */
@@ -128,7 +129,7 @@
/* extern void reset_for_srm(void); */

/* time.c */
-extern void timer_interrupt(int irq, void *dev, struct pt_regs * regs);
+extern irqreturn_t timer_interrupt(int irq, void *dev, struct pt_regs * regs);
extern void common_init_rtc(void);
extern unsigned long est_cycle_freq;

diff -Nru a/arch/alpha/kernel/time.c b/arch/alpha/kernel/time.c
--- a/arch/alpha/kernel/time.c Mon Apr 21 17:00:46 2003
+++ b/arch/alpha/kernel/time.c Mon Apr 21 17:00:46 2003
@@ -94,7 +94,7 @@
* timer_interrupt() needs to keep up the real-time clock,
* as well as call the "do_timer()" routine every clocktick
*/
-void timer_interrupt(int irq, void *dev, struct pt_regs * regs)
+irqreturn_t timer_interrupt(int irq, void *dev, struct pt_regs * regs)
{
unsigned long delta;
__u32 now;
@@ -139,6 +139,7 @@
}

write_sequnlock(&xtime_lock);
+ return IRQ_HANDLED;
}

void

-- 
Places change, faces change. Life is so very strange.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/