summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Couzens <lynxis@fe80.eu>2016-12-01 02:51:11 +0100
committerAlexander Couzens <lynxis@fe80.eu>2017-03-13 10:35:47 +0100
commitb0985ce1023b05a3dfa2366a12d725a38af258eb (patch)
treeab4a1dcd248f8d8a724ca4b09ec79eb750c1e17d
parent1729041aeda9a4b1e3ebb84a6fac4f177cde78e2 (diff)
HACK: libbsc/rbs2000: delay the ALTRQ request by 3 sec
-rw-r--r--openbsc/include/openbsc/gsm_data_shared.h1
-rw-r--r--openbsc/src/libbsc/abis_om2000.c13
2 files changed, 12 insertions, 2 deletions
diff --git a/openbsc/include/openbsc/gsm_data_shared.h b/openbsc/include/openbsc/gsm_data_shared.h
index 607b35f..72cdc55 100644
--- a/openbsc/include/openbsc/gsm_data_shared.h
+++ b/openbsc/include/openbsc/gsm_data_shared.h
@@ -715,6 +715,7 @@ struct gsm_bts {
struct om2k_mo om2k_mo;
struct gsm_abis_mo mo;
struct llist_head conn_groups;
+ struct osmo_timer_list delay_superchannel;
} is;
struct {
struct om2k_mo om2k_mo;
diff --git a/openbsc/src/libbsc/abis_om2000.c b/openbsc/src/libbsc/abis_om2000.c
index 2ec28d8..55f35dd 100644
--- a/openbsc/src/libbsc/abis_om2000.c
+++ b/openbsc/src/libbsc/abis_om2000.c
@@ -1652,6 +1652,11 @@ static void om2k_mo_st_wait_cfg_res(struct osmo_fsm_inst *fi, uint32_t event, vo
abis_om2k_tx_enable_req(omfp->trx->bts, &omfp->mo->addr);
}
+static void om2k_delay_superchannel_wait_enable_res(void *data) {
+ struct gsm_bts *bts = data;
+ e1inp_ericsson_set_altc(bts->oml_link->ts->line, 1);
+}
+
static void om2k_mo_st_wait_enable_accept(struct osmo_fsm_inst *fi, uint32_t event, void *data)
{
struct om2k_mo_fsm_priv *omfp = fi->priv;
@@ -1663,8 +1668,12 @@ static void om2k_mo_st_wait_enable_accept(struct osmo_fsm_inst *fi, uint32_t eve
break;
case OM2K_MSGT_ENABLE_REQ_ACK:
if (omfp->mo->addr.class == OM2K_MO_CLS_IS &&
- omfp->trx->bts->rbs2000.use_superchannel)
- e1inp_ericsson_set_altc(omfp->trx->bts->oml_link->ts->line, 1);
+ omfp->trx->bts->rbs2000.use_superchannel) {
+ omfp->trx->bts->rbs2000.is.delay_superchannel.data = omfp->trx->bts;
+ omfp->trx->bts->rbs2000.is.delay_superchannel.cb = om2k_delay_superchannel_wait_enable_res;
+ osmo_timer_add(&omfp->trx->bts->rbs2000.is.delay_superchannel);
+ osmo_timer_schedule(&omfp->trx->bts->rbs2000.is.delay_superchannel, 3, 0);
+ }
osmo_fsm_inst_state_chg(fi, OM2K_ST_WAIT_ENABLE_RES,
OM2K_TIMEOUT, 0);
}