diff options
author | Max <msuraev@sysmocom.de> | 2017-09-20 17:55:28 +0200 |
---|---|---|
committer | Max <msuraev@sysmocom.de> | 2018-01-26 12:57:05 +0100 |
commit | d000d80968ce6292d6715008ed803ec1f41b6a10 (patch) | |
tree | 3231deb5de5b74a10083c167391352ecaeacaf2f /tests | |
parent | 92e9c17aec02006a38922c41f9c5b59df6c45ea0 (diff) |
Simplify TS alloc: use defines for constants
* define and use constant for occupied TFI instead copying the same
magic number all over the place
* use libosmocore's define for bit pretty-printer
Change-Id: I2699ceebf0cbec01652a02fa68ccc9e9419d0293
Related: OS#2282
Diffstat (limited to 'tests')
-rw-r--r-- | tests/alloc/AllocTest.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/alloc/AllocTest.cpp b/tests/alloc/AllocTest.cpp index 6e344dcb..1c98e462 100644 --- a/tests/alloc/AllocTest.cpp +++ b/tests/alloc/AllocTest.cpp @@ -585,17 +585,17 @@ static unsigned alloc_many_tbfs(BTS *the_bts, unsigned min_class, continue; if (ul_tbf && - pdch->assigned_tfi(GPRS_RLCMAC_DL_TBF) != 0xffffffff) + pdch->assigned_tfi(GPRS_RLCMAC_DL_TBF) != NO_FREE_TFI) continue; if (dl_tbf && - pdch->assigned_tfi(GPRS_RLCMAC_UL_TBF) != 0xffffffff) + pdch->assigned_tfi(GPRS_RLCMAC_UL_TBF) != NO_FREE_TFI) continue; busy_slots |= 1 << i; } - printf(" TBF[%d] class %d reserves %c%c%c%c%c%c%c%c\n", + printf(" TBF[%d] class %d reserves " OSMO_BIT_SPEC "\n", tfi, ms_class, get_dir_char(0x01, ul_slots, dl_slots, busy_slots), get_dir_char(0x02, ul_slots, dl_slots, busy_slots), |