diff options
author | Daniel Willmann <dwillmann@sysmocom.de> | 2014-07-10 17:44:06 +0200 |
---|---|---|
committer | Daniel Willmann <daniel@totalueberwachung.de> | 2014-07-16 19:03:36 +0200 |
commit | 078bb713e1f00b0f2d045baa7fd4e0eb254cdf29 (patch) | |
tree | 9a29d30c5d2bdce4514f723775046771a10fb712 /src | |
parent | 2207c5e4ef0565ab782196a80cc45dcc458938e4 (diff) |
tbf: Add ul and dl TBF types and allocate them in tbf_alloc()
Ticket: SYS#389
Sponsored-by: On-Waves ehf
Diffstat (limited to 'src')
-rw-r--r-- | src/tbf.cpp | 6 | ||||
-rw-r--r-- | src/tbf.h | 6 |
2 files changed, 11 insertions, 1 deletions
diff --git a/src/tbf.cpp b/src/tbf.cpp index f913f970..39549f1e 100644 --- a/src/tbf.cpp +++ b/src/tbf.cpp @@ -495,7 +495,11 @@ struct gprs_rlcmac_tbf *tbf_alloc(struct gprs_rlcmac_bts *bts, if (trx >= 8 || tfi >= 32) return NULL; - tbf = talloc_zero(tall_pcu_ctx, struct gprs_rlcmac_tbf); + if (dir == GPRS_RLCMAC_UL_TBF) + tbf = talloc_zero(tall_pcu_ctx, struct gprs_rlcmac_ul_tbf); + else + tbf = talloc_zero(tall_pcu_ctx, struct gprs_rlcmac_dl_tbf); + if (!tbf) return NULL; @@ -326,6 +326,12 @@ inline time_t gprs_rlcmac_tbf::created_ts() const return m_created_ts; } +struct gprs_rlcmac_dl_tbf : public gprs_rlcmac_tbf { +}; + +struct gprs_rlcmac_ul_tbf : public gprs_rlcmac_tbf { +}; + #endif #ifdef __cplusplus |