aboutsummaryrefslogtreecommitdiffstats
path: root/include/osmo-bts
diff options
context:
space:
mode:
authorMax <msuraev@sysmocom.de>2016-11-04 17:19:52 +0100
committerHarald Welte <laforge@gnumonks.org>2016-12-01 14:49:43 +0000
commitaabeb2eae40bd8d5fc713fcf39e96ff14ad991b2 (patch)
treefbe549153c93d9cbf524ef012c1c4ededcdfe2d2 /include/osmo-bts
parentf4b238f91efddbfc3bc8456bdfef9a2354103c99 (diff)
DTX DL AMR: rewrite FSM recursion
Add explicit state for recursion (sending the different payload data in response to the RTS request for same FN) and corresponding transition. Remove ST_FACCH_V as with new explicit recursion handling it becomes unreacheable. This makes it easier to maintain preemption (interruption of current procedure due to FACCH or Inhibition). This also reduces the number of possible transitions out of each state thus reducing graph's cyclomatic complexity. Change-Id: If39b68083d23a4a35f468a5d75f54eb733ebfd14
Diffstat (limited to 'include/osmo-bts')
-rw-r--r--include/osmo-bts/dtx_dl_amr_fsm.h5
-rw-r--r--include/osmo-bts/msg_utils.h2
2 files changed, 6 insertions, 1 deletions
diff --git a/include/osmo-bts/dtx_dl_amr_fsm.h b/include/osmo-bts/dtx_dl_amr_fsm.h
index 8b195953..4fb2f251 100644
--- a/include/osmo-bts/dtx_dl_amr_fsm.h
+++ b/include/osmo-bts/dtx_dl_amr_fsm.h
@@ -14,10 +14,13 @@ enum dtx_dl_amr_fsm_states {
ST_SID_F2,
ST_F1_INH,
ST_U_INH,
+ ST_F1_INH_REC,
+ ST_U_INH_REC,
ST_SID_U,
ST_ONSET_V,
ST_ONSET_F,
- ST_FACCH_V,
+ ST_ONSET_V_REC,
+ ST_ONSET_F_REC,
ST_FACCH,
};
diff --git a/include/osmo-bts/msg_utils.h b/include/osmo-bts/msg_utils.h
index 4f9868ca..73210455 100644
--- a/include/osmo-bts/msg_utils.h
+++ b/include/osmo-bts/msg_utils.h
@@ -29,6 +29,8 @@ enum {
void lchan_set_marker(bool t, struct gsm_lchan *lchan);
bool dtx_dl_amr_enabled(const struct gsm_lchan *lchan);
void dtx_dispatch(struct gsm_lchan *lchan, enum dtx_dl_amr_fsm_events e);
+bool dtx_recursion(const struct gsm_lchan *lchan);
+void dtx_int_signal(struct gsm_lchan *lchan);
void dtx_cache_payload(struct gsm_lchan *lchan, const uint8_t *l1_payload,
size_t length, uint32_t fn, int update);
int dtx_dl_amr_fsm_step(struct gsm_lchan *lchan, const uint8_t *rtp_pl,