aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax <msuraev@sysmocom.de>2016-10-05 17:29:02 +0200
committerMax <msuraev@sysmocom.de>2016-10-12 11:22:22 +0000
commit1e646f02f4e87544d88775e30787b6a9f7768169 (patch)
tree7e4506f120ad18d1b231a538aebc403725fefe44
parent756fb30c8abeb14bcde6b6bf8dfc50554f0838bd (diff)
DTX DL: use FSM for AMR
- consolidate all DTX-specific things in a separate struct - rename struct fields to better reflect meaning - add pointer to DL FSM for AMR - remove unused flag - expand buffer to hold cached payload alongside with CMR/CMI Change-Id: Idac8609faf9b5ced818fde899ccfc6ed0c42e8fd
-rw-r--r--openbsc/include/openbsc/gsm_data_shared.h21
1 files changed, 9 insertions, 12 deletions
diff --git a/openbsc/include/openbsc/gsm_data_shared.h b/openbsc/include/openbsc/gsm_data_shared.h
index 1e3855f97..d88995970 100644
--- a/openbsc/include/openbsc/gsm_data_shared.h
+++ b/openbsc/include/openbsc/gsm_data_shared.h
@@ -295,23 +295,20 @@ struct gsm_lchan {
struct {
struct amr_multirate_conf amr_mr;
struct {
- uint8_t buf[18];
+ struct osmo_fsm_inst *dl_amr_fsm;
+ uint8_t cache[20];
uint8_t len;
uint32_t fn;
bool is_update;
- } last_sid;
- /* FIXME: 2 flags below are mutually exclusive - is it worth it
- to merge them? */
- /* set for each SID frame to detect talkspurt for codecs without
- explicit ONSET event */
- bool ul_sid;
- /* set for each SID_FIRST_P1 sent to L1 but not followed by
- either of _P2 or InH */
- bool dl_fst;
+ /* set for each SID frame to detect talkspurt for codecs
+ without explicit ONSET event */
+ bool ul_sid;
+ /* indicates if DTXd was active during DL measurement
+ period */
+ bool dl_active;
+ } dtx;
uint8_t last_cmr;
uint32_t last_fn;
- /* indicates if DTXd was active during DL measurement period */
- bool dtxd_active;
} tch;
/* BTS-side ciphering state (rx only, bi-directional, ...) */
uint8_t ciph_state;