diff options
author | David Howells <dhowells@redhat.com> | 2006-10-09 12:19:47 +0100 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2006-10-09 12:19:47 +0100 |
commit | 40220c1a192f51695f806d75b1f9970f0f17a6e8 (patch) | |
tree | 86623a8c361420c22c6511b20770057fd9c9881d /arch/m68k | |
parent | 58ba81dba77eab43633ea47d82e96245ae3ff666 (diff) |
IRQ: Use the new typedef for interrupt handler function pointers
Use the new typedef for interrupt handler function pointers rather than
actually spelling out the full thing each time. This was scripted with the
following small shell script:
#!/bin/sh
egrep -nHrl -e 'irqreturn_t[ ]*[(][*]' $* |
while read i
do
echo $i
perl -pi -e 's/irqreturn_t\s*[(]\s*[*]\s*([_a-zA-Z0-9]*)\s*[)]\s*[(]\s*int\s*,\s*void\s*[*]\s*[)]/irq_handler_t \1/g' $i || exit $?
done
Signed-Off-By: David Howells <dhowells@redhat.com>
Diffstat (limited to 'arch/m68k')
-rw-r--r-- | arch/m68k/amiga/config.c | 4 | ||||
-rw-r--r-- | arch/m68k/apollo/config.c | 6 | ||||
-rw-r--r-- | arch/m68k/atari/config.c | 2 | ||||
-rw-r--r-- | arch/m68k/atari/stdma.c | 4 | ||||
-rw-r--r-- | arch/m68k/atari/time.c | 2 | ||||
-rw-r--r-- | arch/m68k/bvme6000/config.c | 6 | ||||
-rw-r--r-- | arch/m68k/hp300/time.c | 4 | ||||
-rw-r--r-- | arch/m68k/hp300/time.h | 2 | ||||
-rw-r--r-- | arch/m68k/kernel/ints.c | 2 | ||||
-rw-r--r-- | arch/m68k/kernel/setup.c | 2 | ||||
-rw-r--r-- | arch/m68k/mac/config.c | 4 | ||||
-rw-r--r-- | arch/m68k/mac/via.c | 2 | ||||
-rw-r--r-- | arch/m68k/mvme147/config.c | 6 | ||||
-rw-r--r-- | arch/m68k/mvme16x/config.c | 6 | ||||
-rw-r--r-- | arch/m68k/q40/config.c | 2 | ||||
-rw-r--r-- | arch/m68k/q40/q40ints.c | 4 | ||||
-rw-r--r-- | arch/m68k/sun3/config.c | 4 | ||||
-rw-r--r-- | arch/m68k/sun3x/time.c | 2 | ||||
-rw-r--r-- | arch/m68k/sun3x/time.h | 2 |
19 files changed, 33 insertions, 33 deletions
diff --git a/arch/m68k/amiga/config.c b/arch/m68k/amiga/config.c index 6f63d62bd7d6..3204f412cad8 100644 --- a/arch/m68k/amiga/config.c +++ b/arch/m68k/amiga/config.c @@ -83,7 +83,7 @@ static char amiga_model_name[13] = "Amiga "; extern char m68k_debug_device[]; -static void amiga_sched_init(irqreturn_t (*handler)(int, void *)); +static void amiga_sched_init(irq_handler_t handler); /* amiga specific irq functions */ extern void amiga_init_IRQ (void); static void amiga_get_model(char *model); @@ -487,7 +487,7 @@ void __init config_amiga(void) static unsigned short jiffy_ticks; -static void __init amiga_sched_init(irqreturn_t (*timer_routine)(int, void *)) +static void __init amiga_sched_init(irq_handler_t timer_routine) { static struct resource sched_res = { .name = "timer", .start = 0x00bfd400, .end = 0x00bfd5ff, diff --git a/arch/m68k/apollo/config.c b/arch/m68k/apollo/config.c index b2eea00796ac..cb8e7609df4c 100644 --- a/arch/m68k/apollo/config.c +++ b/arch/m68k/apollo/config.c @@ -25,7 +25,7 @@ u_long cpuctrl_physaddr; u_long timer_physaddr; u_long apollo_model; -extern void dn_sched_init(irqreturn_t (*handler)(int,void *)); +extern void dn_sched_init(irq_handler_t handler); extern void dn_init_IRQ(void); extern unsigned long dn_gettimeoffset(void); extern int dn_dummy_hwclk(int, struct rtc_time *); @@ -176,7 +176,7 @@ void config_apollo(void) { irqreturn_t dn_timer_int(int irq, void *dev_id) { - irqreturn_t (*timer_handler)(int, void *) = dev_id; + irq_handler_t timer_handler = dev_id; volatile unsigned char x; @@ -188,7 +188,7 @@ irqreturn_t dn_timer_int(int irq, void *dev_id) return IRQ_HANDLED; } -void dn_sched_init(irqreturn_t (*timer_routine)(int, void *)) +void dn_sched_init(irq_handler_t timer_routine) { /* program timer 1 */ *(volatile unsigned char *)(timer+3)=0x01; diff --git a/arch/m68k/atari/config.c b/arch/m68k/atari/config.c index 76760eebbbc5..ca5cd4344e3d 100644 --- a/arch/m68k/atari/config.c +++ b/arch/m68k/atari/config.c @@ -62,7 +62,7 @@ static void atari_heartbeat( int on ); #endif /* atari specific timer functions (in time.c) */ -extern void atari_sched_init(irqreturn_t (*)(int, void *)); +extern void atari_sched_init(irq_handler_t ); extern unsigned long atari_gettimeoffset (void); extern int atari_mste_hwclk (int, struct rtc_time *); extern int atari_tt_hwclk (int, struct rtc_time *); diff --git a/arch/m68k/atari/stdma.c b/arch/m68k/atari/stdma.c index 5283c73d3f77..d64b5804e980 100644 --- a/arch/m68k/atari/stdma.c +++ b/arch/m68k/atari/stdma.c @@ -44,7 +44,7 @@ static int stdma_locked; /* the semaphore */ /* int func to be called */ -static irqreturn_t (*stdma_isr)(int, void *); +static irq_handler_t stdma_isr; static void *stdma_isr_data; /* data passed to isr */ static DECLARE_WAIT_QUEUE_HEAD(stdma_wait); /* wait queue for ST-DMA */ @@ -75,7 +75,7 @@ static irqreturn_t stdma_int (int irq, void *dummy); * */ -void stdma_lock(irqreturn_t (*handler)(int, void *), void *data) +void stdma_lock(irq_handler_t handler, void *data) { unsigned long flags; diff --git a/arch/m68k/atari/time.c b/arch/m68k/atari/time.c index b8fe71cfc62c..c44df4a4a331 100644 --- a/arch/m68k/atari/time.c +++ b/arch/m68k/atari/time.c @@ -20,7 +20,7 @@ #include <asm/atariints.h> void __init -atari_sched_init(irqreturn_t (*timer_routine)(int, void *)) +atari_sched_init(irq_handler_t timer_routine) { /* set Timer C data Register */ mfp.tim_dt_c = INT_TICKS; diff --git a/arch/m68k/bvme6000/config.c b/arch/m68k/bvme6000/config.c index df64efc940c9..896ae3d3d919 100644 --- a/arch/m68k/bvme6000/config.c +++ b/arch/m68k/bvme6000/config.c @@ -38,7 +38,7 @@ static void bvme6000_get_model(char *model); static int bvme6000_get_hardware_list(char *buffer); -extern void bvme6000_sched_init(irqreturn_t (*handler)(int, void *)); +extern void bvme6000_sched_init(irq_handler_t handler); extern unsigned long bvme6000_gettimeoffset (void); extern int bvme6000_hwclk (int, struct rtc_time *); extern int bvme6000_set_clock_mmss (unsigned long); @@ -52,7 +52,7 @@ static unsigned char bin2bcd (unsigned char b); /* Save tick handler routine pointer, will point to do_timer() in * kernel/sched.c, called via bvme6000_process_int() */ -static irqreturn_t (*tick_handler)(int, void *); +static irq_handler_t tick_handler; int bvme6000_parse_bootinfo(const struct bi_record *bi) @@ -190,7 +190,7 @@ static irqreturn_t bvme6000_timer_int (int irq, void *dev_id) * so divide by 8 to get the microsecond result. */ -void bvme6000_sched_init (irqreturn_t (*timer_routine)(int, void *)) +void bvme6000_sched_init (irq_handler_t timer_routine) { volatile RtcPtr_t rtc = (RtcPtr_t)BVME_RTC_BASE; unsigned char msr = rtc->msr & 0xc0; diff --git a/arch/m68k/hp300/time.c b/arch/m68k/hp300/time.c index 086058fd8383..dd7c8a2583d3 100644 --- a/arch/m68k/hp300/time.c +++ b/arch/m68k/hp300/time.c @@ -39,7 +39,7 @@ static irqreturn_t hp300_tick(int irq, void *dev_id) { unsigned long tmp; - irqreturn_t (*vector)(int, void *) = dev_id; + irq_handler_t vector = dev_id; in_8(CLOCKBASE + CLKSR); asm volatile ("movpw %1@(5),%0" : "=d" (tmp) : "a" (CLOCKBASE)); /* Turn off the network and SCSI leds */ @@ -63,7 +63,7 @@ unsigned long hp300_gettimeoffset(void) return (USECS_PER_JIFFY * ticks) / INTVAL; } -void __init hp300_sched_init(irqreturn_t (*vector)(int, void *)) +void __init hp300_sched_init(irq_handler_t vector) { out_8(CLOCKBASE + CLKCR2, 0x1); /* select CR1 */ out_8(CLOCKBASE + CLKCR1, 0x1); /* reset */ diff --git a/arch/m68k/hp300/time.h b/arch/m68k/hp300/time.h index ca66a039d6f2..f5b3d098b0f5 100644 --- a/arch/m68k/hp300/time.h +++ b/arch/m68k/hp300/time.h @@ -1,4 +1,4 @@ -extern void hp300_sched_init(irqreturn_t (*vector)(int, void *)); +extern void hp300_sched_init(irq_handler_t vector); extern unsigned long hp300_gettimeoffset (void); diff --git a/arch/m68k/kernel/ints.c b/arch/m68k/kernel/ints.c index 6fa893fc5fd6..849c9488c7f8 100644 --- a/arch/m68k/kernel/ints.c +++ b/arch/m68k/kernel/ints.c @@ -216,7 +216,7 @@ int setup_irq(unsigned int irq, struct irq_node *node) } int request_irq(unsigned int irq, - irqreturn_t (*handler) (int, void *), + irq_handler_t handler, unsigned long flags, const char *devname, void *dev_id) { struct irq_node *node; diff --git a/arch/m68k/kernel/setup.c b/arch/m68k/kernel/setup.c index 869c4861346e..42d5b85f3350 100644 --- a/arch/m68k/kernel/setup.c +++ b/arch/m68k/kernel/setup.c @@ -64,7 +64,7 @@ static char m68k_command_line[CL_SIZE]; char m68k_debug_device[6] = ""; -void (*mach_sched_init) (irqreturn_t (*handler)(int, void *)) __initdata = NULL; +void (*mach_sched_init) (irq_handler_t handler) __initdata = NULL; /* machine dependent irq functions */ void (*mach_init_IRQ) (void) __initdata = NULL; void (*mach_get_model) (char *model); diff --git a/arch/m68k/mac/config.c b/arch/m68k/mac/config.c index 029bae65c5d1..562b38d00180 100644 --- a/arch/m68k/mac/config.c +++ b/arch/m68k/mac/config.c @@ -72,7 +72,7 @@ extern int show_mac_interrupts(struct seq_file *, void *); extern void iop_preinit(void); extern void iop_init(void); extern void via_init(void); -extern void via_init_clock(irqreturn_t (*func)(int, void *)); +extern void via_init_clock(irq_handler_t func); extern void via_flush_cache(void); extern void oss_init(void); extern void psc_init(void); @@ -88,7 +88,7 @@ extern void mac_debugging_long(int, long); static void mac_get_model(char *str); -static void mac_sched_init(irqreturn_t (*vector)(int, void *)) +static void mac_sched_init(irq_handler_t vector) { via_init_clock(vector); } diff --git a/arch/m68k/mac/via.c b/arch/m68k/mac/via.c index 9b6c80c4bbe2..e27735be2924 100644 --- a/arch/m68k/mac/via.c +++ b/arch/m68k/mac/via.c @@ -235,7 +235,7 @@ void __init via_init(void) * Start the 100 Hz clock */ -void __init via_init_clock(irqreturn_t (*func)(int, void *)) +void __init via_init_clock(irq_handler_t func) { via1[vACR] |= 0x40; via1[vT1LL] = MAC_CLOCK_LOW; diff --git a/arch/m68k/mvme147/config.c b/arch/m68k/mvme147/config.c index c864d6415180..4a7df9c3f85a 100644 --- a/arch/m68k/mvme147/config.c +++ b/arch/m68k/mvme147/config.c @@ -38,7 +38,7 @@ static void mvme147_get_model(char *model); static int mvme147_get_hardware_list(char *buffer); -extern void mvme147_sched_init(irqreturn_t (*handler)(int, void *)); +extern void mvme147_sched_init(irq_handler_t handler); extern unsigned long mvme147_gettimeoffset (void); extern int mvme147_hwclk (int, struct rtc_time *); extern int mvme147_set_clock_mmss (unsigned long); @@ -51,7 +51,7 @@ static int bcd2int (unsigned char b); /* Save tick handler routine pointer, will point to do_timer() in * kernel/sched.c, called via mvme147_process_int() */ -irqreturn_t (*tick_handler)(int, void *); +irq_handler_t tick_handler; int mvme147_parse_bootinfo(const struct bi_record *bi) @@ -122,7 +122,7 @@ static irqreturn_t mvme147_timer_int (int irq, void *dev_id) } -void mvme147_sched_init (irqreturn_t (*timer_routine)(int, void *)) +void mvme147_sched_init (irq_handler_t timer_routine) { tick_handler = timer_routine; request_irq (PCC_IRQ_TIMER1, mvme147_timer_int, diff --git a/arch/m68k/mvme16x/config.c b/arch/m68k/mvme16x/config.c index 2c91cee17093..c829ebb6b1af 100644 --- a/arch/m68k/mvme16x/config.c +++ b/arch/m68k/mvme16x/config.c @@ -42,7 +42,7 @@ static MK48T08ptr_t volatile rtc = (MK48T08ptr_t)MVME_RTC_BASE; static void mvme16x_get_model(char *model); static int mvme16x_get_hardware_list(char *buffer); -extern void mvme16x_sched_init(irqreturn_t (*handler)(int, void *)); +extern void mvme16x_sched_init(irq_handler_t handler); extern unsigned long mvme16x_gettimeoffset (void); extern int mvme16x_hwclk (int, struct rtc_time *); extern int mvme16x_set_clock_mmss (unsigned long); @@ -54,7 +54,7 @@ int bcd2int (unsigned char b); /* Save tick handler routine pointer, will point to do_timer() in * kernel/sched.c, called via mvme16x_process_int() */ -static irqreturn_t (*tick_handler)(int, void *); +static irq_handler_t tick_handler; unsigned short mvme16x_config; @@ -224,7 +224,7 @@ static irqreturn_t mvme16x_timer_int (int irq, void *dev_id) return tick_handler(irq, dev_id); } -void mvme16x_sched_init (irqreturn_t (*timer_routine)(int, void *)) +void mvme16x_sched_init (irq_handler_t timer_routine) { p_bdid p = &mvme_bdid; int irq; diff --git a/arch/m68k/q40/config.c b/arch/m68k/q40/config.c index 5123f693948f..92f873cc7060 100644 --- a/arch/m68k/q40/config.c +++ b/arch/m68k/q40/config.c @@ -39,7 +39,7 @@ extern irqreturn_t q40_process_int (int level, struct pt_regs *regs); extern void q40_init_IRQ (void); static void q40_get_model(char *model); static int q40_get_hardware_list(char *buffer); -extern void q40_sched_init(irqreturn_t (*handler)(int, void *)); +extern void q40_sched_init(irq_handler_t handler); extern unsigned long q40_gettimeoffset (void); extern int q40_hwclk (int, struct rtc_time *); diff --git a/arch/m68k/q40/q40ints.c b/arch/m68k/q40/q40ints.c index 4a4ee4dfa6f1..31cc07d8cec4 100644 --- a/arch/m68k/q40/q40ints.c +++ b/arch/m68k/q40/q40ints.c @@ -125,7 +125,7 @@ void q40_mksound(unsigned int hz, unsigned int ticks) sound_ticks = ticks << 1; } -static irqreturn_t (*q40_timer_routine)(int, void *); +static irq_handler_t q40_timer_routine; static irqreturn_t q40_timer_int (int irq, void * dev) { @@ -142,7 +142,7 @@ static irqreturn_t q40_timer_int (int irq, void * dev) return IRQ_HANDLED; } -void q40_sched_init (irqreturn_t (*timer_routine)(int, void *)) +void q40_sched_init (irq_handler_t timer_routine) { int timer_irq; diff --git a/arch/m68k/sun3/config.c b/arch/m68k/sun3/config.c index 43e4aa3f404a..4851b8437a87 100644 --- a/arch/m68k/sun3/config.c +++ b/arch/m68k/sun3/config.c @@ -35,7 +35,7 @@ extern char _text, _end; char sun3_reserved_pmeg[SUN3_PMEGS_NUM]; extern unsigned long sun3_gettimeoffset(void); -extern void sun3_sched_init(irqreturn_t (*handler)(int, void *)); +extern void sun3_sched_init(irq_handler_t handler); extern void sun3_get_model (char* model); extern void idprom_init (void); extern int sun3_hwclk(int set, struct rtc_time *t); @@ -162,7 +162,7 @@ void __init config_sun3(void) sun3_bootmem_alloc(memory_start, memory_end); } -void __init sun3_sched_init(irqreturn_t (*timer_routine)(int, void *)) +void __init sun3_sched_init(irq_handler_t timer_routine) { sun3_disable_interrupts(); intersil_clock->cmd_reg=(INTERSIL_RUN|INTERSIL_INT_DISABLE|INTERSIL_24H_MODE); diff --git a/arch/m68k/sun3x/time.c b/arch/m68k/sun3x/time.c index 33eb1ecc888a..f5eaafb00d21 100644 --- a/arch/m68k/sun3x/time.c +++ b/arch/m68k/sun3x/time.c @@ -90,7 +90,7 @@ static void sun3x_timer_tick(int irq, void *dev_id, struct pt_regs *regs) } #endif -void __init sun3x_sched_init(irqreturn_t (*vector)(int, void *)) +void __init sun3x_sched_init(irq_handler_t vector) { sun3_disable_interrupts(); diff --git a/arch/m68k/sun3x/time.h b/arch/m68k/sun3x/time.h index e39079c781d8..6909e1297534 100644 --- a/arch/m68k/sun3x/time.h +++ b/arch/m68k/sun3x/time.h @@ -3,7 +3,7 @@ extern int sun3x_hwclk(int set, struct rtc_time *t); unsigned long sun3x_gettimeoffset (void); -void sun3x_sched_init(irqreturn_t (*vector)(int, void *)); +void sun3x_sched_init(irq_handler_t vector); struct mostek_dt { volatile unsigned char csr; |