summaryrefslogtreecommitdiff
path: root/cpu/nios/interrupts.c
diff options
context:
space:
mode:
Diffstat (limited to 'cpu/nios/interrupts.c')
-rw-r--r--cpu/nios/interrupts.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/cpu/nios/interrupts.c b/cpu/nios/interrupts.c
index 31eabde53d6..450946bbc3b 100644
--- a/cpu/nios/interrupts.c
+++ b/cpu/nios/interrupts.c
@@ -128,6 +128,10 @@ int interrupt_init (void)
tmr->control &= ~NIOS_TIMER_ITO;
tmr->control |= NIOS_TIMER_STOP;
+#if defined(CFG_NIOS_TMRCNT)
+ tmr->periodl = CFG_NIOS_TMRCNT & 0xffff;
+ tmr->periodh = (CFG_NIOS_TMRCNT >> 16) & 0xffff;
+#endif
#endif
for (vec=0; vec<64; vec++ ) {