diff options
author | Jacob Erlbeck <jerlbeck@sysmocom.de> | 2015-06-02 12:33:30 +0200 |
---|---|---|
committer | Jacob Erlbeck <jerlbeck@sysmocom.de> | 2015-06-08 09:38:49 +0200 |
commit | befc760f8677d794e5a0dbc1f02f8ac85b649aa0 (patch) | |
tree | 4e8bf7176797ed929df9d15fc58d71a5990ea5d9 /src/gprs_ms.cpp | |
parent | 489a2b35d87610fb077a51de696555a54e5fb247 (diff) |
tbf: Store MS class in GprsMs objects
The ms_class value is a property of the MS and thus belongs to the
GprsMs class. Nevertheless the MS object is created after the TLLI
gets known, so the value still has to be stored in the TBF initially.
This commit add the ms_class value to the GprsMs class and introduces
TBF accessor functions which either access that object or, if that is
not available, the value stored locally.
Ticket: #1674
Sponsored-by: On-Waves ehf
Diffstat (limited to 'src/gprs_ms.cpp')
-rw-r--r-- | src/gprs_ms.cpp | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/gprs_ms.cpp b/src/gprs_ms.cpp index d047cf57..1ae0fc6b 100644 --- a/src/gprs_ms.cpp +++ b/src/gprs_ms.cpp @@ -72,6 +72,7 @@ GprsMs::GprsMs(uint32_t tlli) : m_new_ul_tlli(0), m_new_dl_tlli(0), m_ta(0), + m_ms_class(0), m_is_idle(true), m_ref(0), m_list(this) @@ -325,3 +326,15 @@ void GprsMs::set_ta(uint8_t ta_) m_ta = ta_; } +void GprsMs::set_ms_class(uint8_t ms_class_) +{ + if (ms_class_ == m_ms_class) + return; + + LOGP(DRLCMAC, LOGL_INFO, + "Modifying MS object, TLLI = 0x%08x, MS class %d -> %d\n", + tlli(), m_ms_class, ms_class_); + + m_ms_class = ms_class_; +} + |