From 773453e187d3a0509a6f9e81823add27614f31de Mon Sep 17 00:00:00 2001 From: lakshbhatia Date: Fri, 4 Mar 2016 18:25:03 +0100 Subject: [PATCH] stm32l1/timer: fix callback argument initialization --- cpu/stm32l1/periph/timer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cpu/stm32l1/periph/timer.c b/cpu/stm32l1/periph/timer.c index ac6f190481..03c074b9b8 100644 --- a/cpu/stm32l1/periph/timer.c +++ b/cpu/stm32l1/periph/timer.c @@ -56,7 +56,7 @@ int timer_init(tim_t dev, unsigned long freq, timer_cb_t cb, void *arg) tim = _tim(dev); /* save callback */ isr_ctx[dev].cb = cb; - isr_ctx[dev].cb = arg; + isr_ctx[dev].arg = arg; /* enable peripheral clock */ RCC->APB1ENR |= (1 << timer_config[dev].rcc); /* reset timer and configure to up-counting mode */