From 9b30c7f46e2c55aed06cea8d1daa9093f331fb20 Mon Sep 17 00:00:00 2001 From: Holger Hans Peter Freyther Date: Thu, 17 Oct 2013 19:59:56 +0200 Subject: bts: Move the frame_number into the BTS sructure The current_frame is an attribute of the BTS. Move it from the pcu_l1_if.cpp into the BTS. As the next step we can trigger actions depending on the change of the frame. --- src/gsm_timer.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'src/gsm_timer.cpp') diff --git a/src/gsm_timer.cpp b/src/gsm_timer.cpp index 95513b47..d3c59cbc 100644 --- a/src/gsm_timer.cpp +++ b/src/gsm_timer.cpp @@ -33,9 +33,21 @@ static int *nearest_p; #include #include #include +#include + static struct rb_root timer_root = RB_ROOT; +/* + * TODO: make this depend on the BTS. This means that + * all time functions schedule based on the BTS they + * are scheduled on. + */ +static int get_current_fn() +{ + return BTS::main_bts()->current_frame_number(); +} + static void __add_gsm_timer(struct osmo_gsm_timer_list *timer) { struct rb_node **new_node = &(timer_root.rb_node); -- cgit v1.2.3