diff options
author | Jacob Erlbeck <jerlbeck@sysmocom.de> | 2015-07-01 12:19:40 +0200 |
---|---|---|
committer | Jacob Erlbeck <jerlbeck@sysmocom.de> | 2015-07-07 09:35:26 +0200 |
commit | ed46afda6f647e47702379abacf632e7dcc9ee5b (patch) | |
tree | 046fd778dfc72b09e50be23c7d77ad0eaa0a164f /src/gprs_rlcmac_ts_alloc.cpp | |
parent | ea65c72d069c279951c022daf337d99e3aaa670a (diff) |
alloc: Only use common UL slots when calculating the capacity
Currently al possible UL slots are included in the capacity
calculation which is the base of the slot selection. Nevertheless
UL-only slots will never be used, since only one uplink slot (which
must be a common slot) will be used.
This patch changes the code to only include common slots in the
capacity sum.
Note that this might not be optimal if algorithm B supported
multiple uplink slots.
Sponsored-by: On-Waves ehf
Diffstat (limited to 'src/gprs_rlcmac_ts_alloc.cpp')
-rw-r--r-- | src/gprs_rlcmac_ts_alloc.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gprs_rlcmac_ts_alloc.cpp b/src/gprs_rlcmac_ts_alloc.cpp index 0169d49f..0085f819 100644 --- a/src/gprs_rlcmac_ts_alloc.cpp +++ b/src/gprs_rlcmac_ts_alloc.cpp @@ -548,7 +548,8 @@ static int find_multi_slots(struct gprs_rlcmac_bts *bts, c = 32 - pdch->num_reserved(GPRS_RLCMAC_DL_TBF); capacity += c; } - if (tx_window & (1 << ts)) { + /* Only consider common slots for UL */ + if (tx_window & rx_window & (1 << ts)) { c = 32 - pdch->num_reserved(GPRS_RLCMAC_UL_TBF); capacity += c; } |