summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--arch/avr32/cpu/interrupts.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/avr32/cpu/interrupts.c b/arch/avr32/cpu/interrupts.c
index 6681e13..49a00f1 100644
--- a/arch/avr32/cpu/interrupts.c
+++ b/arch/avr32/cpu/interrupts.c
@@ -107,7 +107,7 @@ static int set_interrupt_handler(unsigned int nr, void (*handler)(void),
return 0;
}
-void timer_init(void)
+int timer_init(void)
{
extern void timer_interrupt_handler(void);
u64 tmp;
@@ -120,8 +120,9 @@ void timer_init(void)
tb_factor = (u32)tmp;
if (set_interrupt_handler(0, &timer_interrupt_handler, 3))
- return;
+ return -EINVAL;
/* For all practical purposes, this gives us an overflow interrupt */
sysreg_write(COMPARE, 0xffffffff);
+ return 0;
}