diff options
author | Jacob Erlbeck <jerlbeck@sysmocom.de> | 2015-09-28 18:54:32 +0200 |
---|---|---|
committer | Jacob Erlbeck <jerlbeck@sysmocom.de> | 2015-12-15 15:19:42 +0100 |
commit | 5265f59525157d135c1051f057f836395782c98e (patch) | |
tree | 97cf1d5e7f45a54817e033deab6a026fa97b0e2b /src/tbf.cpp | |
parent | 86b6f05d19c8559b99d548730e54c1a4bfb7beba (diff) |
edge: Enable EGPRS if configured and egprs_ms_class present
Enable the TBF to use EGPRS if the bts->egprs_enabled config variable
has been set via the VTY "egprs" command and if the MS has signaled a
EGPRS multislot class.
Tell the MS to use EGPRS if the condition above holds.
Note that this will cause the MS to use EGPRS RLC block formats for
further messages which are not yet understood by the PCU.
Sponsored-by: On-Waves ehf
Diffstat (limited to 'src/tbf.cpp')
-rw-r--r-- | src/tbf.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/tbf.cpp b/src/tbf.cpp index 2d0aa9fd..590d1151 100644 --- a/src/tbf.cpp +++ b/src/tbf.cpp @@ -546,6 +546,12 @@ static int setup_tbf(struct gprs_rlcmac_tbf *tbf, bts = tbf->bts->bts_data(); + if (egprs_ms_class > 0 && bts->egprs_enabled) { + /* TODO: only for 8PSK, otherwise the GPRS MS class has to be used */ + ms_class = egprs_ms_class; + tbf->enable_egprs(); + } + tbf->m_created_ts = time(NULL); tbf->set_ms_class(ms_class); /* select algorithm */ @@ -924,7 +930,7 @@ struct msgb *gprs_rlcmac_tbf::create_ul_ass(uint32_t fn) Encoding::write_packet_uplink_assignment(bts_data(), ass_vec, m_tfi, (direction == GPRS_RLCMAC_DL_TBF), tlli(), is_tlli_valid(), new_tbf, 1, bts_data()->alpha, - bts_data()->gamma, -1, 0); + bts_data()->gamma, -1, is_egprs_enabled()); bitvec_pack(ass_vec, msgb_put(msg, 23)); RlcMacDownlink_t * mac_control_block = (RlcMacDownlink_t *)talloc_zero(tall_pcu_ctx, RlcMacDownlink_t); LOGP(DRLCMAC, LOGL_DEBUG, "+++++++++++++++++++++++++ TX : Packet Uplink Assignment +++++++++++++++++++++++++\n"); |