summaryrefslogtreecommitdiff
path: root/firmware/target/arm/at91sam
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/arm/at91sam')
-rw-r--r--firmware/target/arm/at91sam/lyre_proto1/timer-lyre_proto1.c4
-rw-r--r--firmware/target/arm/at91sam/lyre_proto1/timer-target.h13
2 files changed, 8 insertions, 9 deletions
diff --git a/firmware/target/arm/at91sam/lyre_proto1/timer-lyre_proto1.c b/firmware/target/arm/at91sam/lyre_proto1/timer-lyre_proto1.c
index 5924438d10..ef5c91169d 100644
--- a/firmware/target/arm/at91sam/lyre_proto1/timer-lyre_proto1.c
+++ b/firmware/target/arm/at91sam/lyre_proto1/timer-lyre_proto1.c
@@ -67,7 +67,7 @@ bool __timer_set(long cycles, bool start)
67 return false; 67 return false;
68} 68}
69 69
70bool __timer_register(void) 70bool __timer_start(void)
71{ 71{
72 bool retval = true; 72 bool retval = true;
73 volatile unsigned long pimr = 0; 73 volatile unsigned long pimr = 0;
@@ -101,7 +101,7 @@ bool __timer_register(void)
101 return retval; 101 return retval;
102} 102}
103 103
104void __timer_unregister(void) 104void __timer_stop(void)
105{ 105{
106 volatile unsigned long pimr = 0; 106 volatile unsigned long pimr = 0;
107 107
diff --git a/firmware/target/arm/at91sam/lyre_proto1/timer-target.h b/firmware/target/arm/at91sam/lyre_proto1/timer-target.h
index d16577b0de..b8298d3d77 100644
--- a/firmware/target/arm/at91sam/lyre_proto1/timer-target.h
+++ b/firmware/target/arm/at91sam/lyre_proto1/timer-target.h
@@ -26,17 +26,16 @@
26#define TIMER_FREQ (49156800/2) 26#define TIMER_FREQ (49156800/2)
27 27
28bool __timer_set(long cycles, bool set); 28bool __timer_set(long cycles, bool set);
29bool __timer_register(void); 29bool __timer_start(void);
30void __timer_unregister(void); 30void __timer_stop(void);
31 31
32#define __TIMER_SET(cycles, set) \ 32#define __TIMER_SET(cycles, set) \
33 __timer_set(cycles, set) 33 __timer_set(cycles, set)
34 34
35#define __TIMER_REGISTER(reg_prio, unregister_callback, cycles, \ 35#define __TIMER_START() \
36 int_prio, timer_callback) \ 36 __timer_start()
37 __timer_register()
38 37
39#define __TIMER_UNREGISTER(...) \ 38#define __TIMER_STOP(...) \
40 __timer_unregister() 39 __timer_stop()
41 40
42#endif /* TIMER_TARGET_H */ 41#endif /* TIMER_TARGET_H */