aboutsummaryrefslogtreecommitdiffstats
path: root/src/bts.cpp
diff options
context:
space:
mode:
authorMax <msuraev@sysmocom.de>2018-01-30 16:56:43 +0100
committerHarald Welte <laforge@gnumonks.org>2018-02-03 15:05:29 +0000
commit5d7f757e4918da9d26189f6c6a5f96938234d309 (patch)
treef26703257fdf9f3a665903cd4ef69f7c0229a41d /src/bts.cpp
parent0fdaa9d383eb22f276fa0404315be3a5bb8718c6 (diff)
TBF: add helpers for assignment type handling
* add function to set/unset given assignment type * log assignment type flag changes * update tests output with additional logs This enables us to carefully track the TBF assignment type transitions. Change-Id: I3fe9d52472be8b7f257e8326b2f84e8e7d7bd1f4 Related: OS#1759
Diffstat (limited to 'src/bts.cpp')
-rw-r--r--src/bts.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bts.cpp b/src/bts.cpp
index 72e1621..3d29ad6 100644
--- a/src/bts.cpp
+++ b/src/bts.cpp
@@ -759,7 +759,7 @@ int BTS::rcv_rach(uint16_t ra, uint32_t Fn, int16_t qta, bool is_11bit,
} else {
tbf->set_ta(ta);
TBF_SET_STATE(tbf, GPRS_RLCMAC_FLOW);
- tbf->state_flags |= (1 << GPRS_RLCMAC_FLAG_CCCH);
+ TBF_ASS_TYPE_SET(tbf, GPRS_RLCMAC_FLAG_CCCH);
T_START(tbf, T3169, m_bts.t3169, 0, "RACH (new UL-TBF)", true);
LOGPTBF(tbf, LOGL_DEBUG, "[UPLINK] START\n");
LOGPTBF(tbf, LOGL_DEBUG, "RX: [PCU <- BTS] RACH "
@@ -1042,7 +1042,7 @@ void gprs_rlcmac_pdch::rcv_control_ack(Packet_Control_Acknowledgement_t *packet,
LOGPTBF(new_tbf, LOGL_INFO,
"The TBF has been confirmed on the PACCH, "
"changed type from CCCH to PACCH\n");
- new_tbf->state_flags |= (1 << GPRS_RLCMAC_FLAG_PACCH);
+ TBF_ASS_TYPE_SET(new_tbf, GPRS_RLCMAC_FLAG_PACCH);
}
TBF_SET_STATE(new_tbf, GPRS_RLCMAC_FLOW);
/* stop pending assignment timer */