aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJacob Erlbeck <jerlbeck@sysmocom.de>2013-11-04 18:13:52 +0100
committerHolger Hans Peter Freyther <holger@moiji-mobile.com>2013-11-05 15:51:19 +0100
commit5b69ec3e720d21753101c9a0e1a38d0926ba3854 (patch)
tree5b07ab53e6858ad895cc8041f3beae007647746a /include
parent08571b158835df3db09cc94686a8fe62d1845cc9 (diff)
sysmobts: Use status flags instead of direct LED access
Currently the LEDs are being accessed directly from within the l1_if.c file. So the handling of rf mute and activate/deactivate both access LED_RF_ACTIVE directly. This may lead to an inconsistent LED status. This patch replaces these calls to sysmobts_led_set() by an abstract equivalent bts_update_status(), that uses a set of independant status ids. The associated values can than be combined into a visible LED status. Currently LED_RF_ACTIVE is on iff BTS_STATUS_RF_ACTIVE is set and BTS_STATUS_RF_MUTE is not set. Sponsored-by: On-Waves ehf
Diffstat (limited to 'include')
-rw-r--r--include/osmo-bts/bts.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/include/osmo-bts/bts.h b/include/osmo-bts/bts.h
index 583c1eb1..e2020350 100644
--- a/include/osmo-bts/bts.h
+++ b/include/osmo-bts/bts.h
@@ -3,6 +3,12 @@
#include <osmo-bts/gsm_data.h>
+enum bts_global_status {
+ BTS_STATUS_RF_ACTIVE,
+ BTS_STATUS_RF_MUTE,
+ BTS_STATUS_LAST,
+};
+
extern void *tall_bts_ctx;
int bts_init(struct gsm_bts *bts);
@@ -27,5 +33,7 @@ int lchan_init_lapdm(struct gsm_lchan *lchan);
void load_timer_start(struct gsm_bts *bts);
+void bts_update_status(enum bts_global_status which, int on);
+
#endif /* _BTS_H */