From 489a2b35d87610fb077a51de696555a54e5fb247 Mon Sep 17 00:00:00 2001 From: Jacob Erlbeck Date: Thu, 28 May 2015 19:07:01 +0200 Subject: tbf: Move the LLC queue to GprsMs Currently the enqueued DL LLC messages which have not yet passed to RLC/MAC encoding are eventually copied from one TBF to the next one (see gprs_rlcmac_dl_tbf::reuse_tbf). Since the enqueued LLC messages are related to a specific MS, they should be stored at that layer. This commit moves the gprs_llc_queue object to GprsMs and changes the TBF's accessor methods accordingly. The LLC copying code is removed from gprs_rlcmac_dl_tbf::reuse_tbf(). Sponsored-by: On-Waves ehf --- src/gprs_ms.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'src/gprs_ms.h') diff --git a/src/gprs_ms.h b/src/gprs_ms.h index db55badf..5c42c50a 100644 --- a/src/gprs_ms.h +++ b/src/gprs_ms.h @@ -25,6 +25,7 @@ struct gprs_rlcmac_dl_tbf; struct gprs_rlcmac_ul_tbf; #include "cxx_linuxlist.h" +#include "llc.h" extern "C" { #include @@ -67,6 +68,9 @@ public: uint8_t ta() const; void set_ta(uint8_t ta); + gprs_llc_queue *llc_queue(); + const gprs_llc_queue *llc_queue() const; + void set_timeout(unsigned secs); void attach_tbf(gprs_rlcmac_tbf *tbf); @@ -104,6 +108,7 @@ private: /* store IMSI for look-up and PCH retransmission */ char m_imsi[16]; uint8_t m_ta; + gprs_llc_queue m_llc_queue; bool m_is_idle; int m_ref; @@ -139,3 +144,14 @@ inline void GprsMs::set_timeout(unsigned secs) { m_delay = secs; } + +inline gprs_llc_queue *GprsMs::llc_queue() +{ + return &m_llc_queue; +} + +inline const gprs_llc_queue *GprsMs::llc_queue() const +{ + return &m_llc_queue; +} + -- cgit v1.2.3