blob: b278ecfb440f70830949f4bb5c21dff723475cb2 [file] [log] [blame]
Holger Hans Peter Freytherb6acfda2013-10-17 19:41:11 +02001/*
2 * Copyright (C) 2013 by Holger Hans Peter Freyther
3 *
4 * All Rights Reserved
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU Affero General Public License as published by
8 * the Free Software Foundation; either version 3 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU Affero General Public License
17 * along with this program. If not, see <http://www.gnu.org/licenses/>.
18 *
19 */
20
21#include <bts.h>
22#include <string.h>
23
24static BTS s_bts;
25
26BTS* BTS::main_bts()
27{
28 return &s_bts;
29}
30
31struct gprs_rlcmac_bts *BTS::bts_data()
32{
33 return &m_bts;
34}
35
36struct gprs_rlcmac_bts *bts_main_data()
37{
38 return BTS::main_bts()->bts_data();
39}
40
41BTS::BTS()
Holger Hans Peter Freyther9b30c7f2013-10-17 19:59:56 +020042 : m_cur_fn(0)
Holger Hans Peter Freytherb6acfda2013-10-17 19:41:11 +020043{
44 memset(&m_bts, 0, sizeof(m_bts));
45 m_bts.bts = this;
46}
Holger Hans Peter Freyther9b30c7f2013-10-17 19:59:56 +020047
48void BTS::set_current_frame_number(int fn)
49{
50 m_cur_fn = fn;
51}