aboutsummaryrefslogtreecommitdiffstats
path: root/src/osmo-bts-litecell15
diff options
context:
space:
mode:
authorMax <msuraev@sysmocom.de>2016-11-11 17:44:57 +0100
committerHarald Welte <laforge@gnumonks.org>2016-12-01 15:20:42 +0000
commit36153239bfd0b633c4d259a9de0a759f41197a2b (patch)
treebcd43bc4395df9b7d9d3da98235f23d43c3ab79b /src/osmo-bts-litecell15
parentaabeb2eae40bd8d5fc713fcf39e96ff14ad991b2 (diff)
Remove duplicated code
Remove lchan deactivation related code duplication to facilitate future use for dynamic CCCH re-activation. Change-Id: Id0d3b19dbfaa16d1734321a07a6eb0355bfd77c9
Diffstat (limited to 'src/osmo-bts-litecell15')
-rw-r--r--src/osmo-bts-litecell15/lc15bts_vty.c3
-rw-r--r--src/osmo-bts-litecell15/oml.c7
2 files changed, 4 insertions, 6 deletions
diff --git a/src/osmo-bts-litecell15/lc15bts_vty.c b/src/osmo-bts-litecell15/lc15bts_vty.c
index c5d404cc..0ffe6634 100644
--- a/src/osmo-bts-litecell15/lc15bts_vty.c
+++ b/src/osmo-bts-litecell15/lc15bts_vty.c
@@ -46,15 +46,14 @@
#include <osmo-bts/gsm_data.h>
#include <osmo-bts/phy_link.h>
#include <osmo-bts/logging.h>
+#include <osmo-bts/bts_model.h>
#include <osmo-bts/vty.h>
#include "lc15bts.h"
#include "l1_if.h"
#include "utils.h"
-
extern int lchan_activate(struct gsm_lchan *lchan);
-extern int lchan_deactivate(struct gsm_lchan *lchan);
#define TRX_STR "Transceiver related commands\n" "TRX number\n"
diff --git a/src/osmo-bts-litecell15/oml.c b/src/osmo-bts-litecell15/oml.c
index 689ba70c..8afa2a2f 100644
--- a/src/osmo-bts-litecell15/oml.c
+++ b/src/osmo-bts-litecell15/oml.c
@@ -1656,10 +1656,9 @@ static void enqueue_rel_marker(struct gsm_lchan *lchan)
queue_sapi_command(lchan, cmd);
}
-int lchan_deactivate(struct gsm_lchan *lchan)
+int bts_model_lchan_deactivate(struct gsm_lchan *lchan)
{
lchan_set_state(lchan, LCHAN_S_REL_REQ);
- lchan->ciph_state = 0; /* FIXME: do this in common/\*.c */
enqueue_rel_marker(lchan);
return 0;
}
@@ -1674,7 +1673,7 @@ static void enqueue_sacch_rel_marker(struct gsm_lchan *lchan)
queue_sapi_command(lchan, cmd);
}
-static int lchan_deactivate_sacch(struct gsm_lchan *lchan)
+int bts_model_lchan_deactivate_sacch(struct gsm_lchan *lchan)
{
enqueue_sacch_rel_marker(lchan);
return 0;
@@ -1858,7 +1857,7 @@ int l1if_rsl_deact_sacch(struct gsm_lchan *lchan)
/* Only de-activate the SACCH if the lchan is active */
if (lchan->state != LCHAN_S_ACTIVE)
return 0;
- return lchan_deactivate_sacch(lchan);
+ return bts_model_lchan_deactivate_sacch(lchan);
}
int bts_model_trx_deact_rf(struct gsm_bts_trx *trx)