aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeels Hofmeyr <neels@hofmeyr.de>2020-11-12 22:51:11 +0100
committerNeels Hofmeyr <neels@hofmeyr.de>2020-11-16 17:02:06 +0100
commit2fa1df31e6da51538933a6f9fb3f039db3dd72e5 (patch)
tree0455a5ded45114e286ee0707d787bbb504c4f25d
parentda16bf7b59699090e5524d7afc44a8f7d76c924f (diff)
handover_test 1 of n: move arfcn into create_bts()
-rw-r--r--tests/handover/handover_test.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/handover/handover_test.c b/tests/handover/handover_test.c
index 84a48af5d..2bb91f08b 100644
--- a/tests/handover/handover_test.c
+++ b/tests/handover/handover_test.c
@@ -174,8 +174,9 @@ static void gen_meas_rep(struct gsm_lchan *lchan)
abis_rsl_rcvmsg(msg);
}
-static struct gsm_bts *create_bts(int arfcn)
+static struct gsm_bts *create_bts()
{
+ static int arfcn = 870;
struct gsm_bts *bts;
struct e1inp_sign_link *rsl_link;
int i;
@@ -187,7 +188,7 @@ static struct gsm_bts *create_bts(int arfcn)
}
bts->location_area_code = 23;
- bts->c0->arfcn = arfcn;
+ bts->c0->arfcn = arfcn++;
bts->codec.efr = 1;
bts->codec.hr = 1;
@@ -1495,12 +1496,11 @@ int main(int argc, char **argv)
while (*test_case) {
if (!strcmp(*test_case, "create-bts")) {
- static int arfcn = 870;
int n = atoi(test_case[1]);
fprintf(stderr, "- Creating %d BTS (one TRX each, "
"TS(1-4) are TCH/F, TS(5-6) are TCH/H)\n", n);
for (i = 0; i < n; i++)
- bts[bts_num + i] = create_bts(arfcn++);
+ bts[bts_num + i] = create_bts();
for (i = 0; i < n; i++) {
if (gsm_generate_si(bts[bts_num + i], SYSINFO_TYPE_2) <= 0)
fprintf(stderr, "Error generating SI2\n");