Skip to content

Commit 1b461d7

Browse files
committed
m68knommu: fix 68360 local setting of timer interrupt handler
Compiling for 68360 based targets fails with: arch/m68k/platform/68360/config.c: In function ‘hw_tick’: arch/m68k/platform/68360/config.c:55:2: error: implicit declaration of function ‘arch_timer_interrupt’ arch/m68k/platform/68360/config.c: At top level: arch/m68k/platform/68360/config.c:64:6: error: conflicting types for ‘hw_timer_init’ arch/m68k/include/asm/machdep.h:36:13: note: previous declaration of ‘hw_timer_init’ was here Changes made to hw_timer_init() didn't get updated in the 68328 timer code. So process and call the "handler" arg that is now passed into that hw_timer_init() function. Signed-off-by: Greg Ungerer <gerg@uclinux.org>
1 parent dc5588a commit 1b461d7

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

‎arch/m68k/platform/68360/config.c‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ extern void m360_cpm_reset(void);
3535
#define OSCILLATOR (unsigned long int)33000000
3636
#endif
3737

38+
static irq_handler_t timer_interrupt;
3839
unsigned long int system_clock;
3940

4041
extern QUICC *pquicc;
@@ -52,7 +53,7 @@ static irqreturn_t hw_tick(int irq, void *dummy)
5253

5354
pquicc->timer_ter1 = 0x0002; /* clear timer event */
5455

55-
return arch_timer_interrupt(irq, dummy);
56+
return timer_interrupt(irq, dummy);
5657
}
5758

5859
static struct irqaction m68360_timer_irq = {
@@ -61,7 +62,7 @@ static struct irqaction m68360_timer_irq = {
6162
.handler = hw_tick,
6263
};
6364

64-
void hw_timer_init(void)
65+
void hw_timer_init(irq_handler_t handler)
6566
{
6667
unsigned char prescaler;
6768
unsigned short tgcr_save;
@@ -94,6 +95,8 @@ void hw_timer_init(void)
9495

9596
pquicc->timer_ter1 = 0x0003; /* clear timer events */
9697

98+
timer_interrupt = handler;
99+
97100
/* enable timer 1 interrupt in CIMR */
98101
setup_irq(CPMVEC_TIMER1, &m68360_timer_irq);
99102

0 commit comments

Comments
 (0)