aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/handover_decision.c
diff options
context:
space:
mode:
authorHarald Welte <laforge@netfilter.org>2009-12-19 21:41:52 +0100
committerHarald Welte <laforge@netfilter.org>2009-12-19 21:41:52 +0100
commitbc814501e8a28f72e16a4662250af01aaa2a1489 (patch)
treea510ceb0879cbb1091c73ffa3d6ca2c78e70124f /openbsc/src/handover_decision.c
parente786c32bc935bb7767335758e92c886322c8aeb5 (diff)
[handover] add VTY parameter to enable/disable handover
Diffstat (limited to 'openbsc/src/handover_decision.c')
-rw-r--r--openbsc/src/handover_decision.c18
1 files changed, 11 insertions, 7 deletions
diff --git a/openbsc/src/handover_decision.c b/openbsc/src/handover_decision.c
index 3605a8e0a..4c08c6664 100644
--- a/openbsc/src/handover_decision.c
+++ b/openbsc/src/handover_decision.c
@@ -88,15 +88,19 @@ static int process_meas_rep(struct gsm_meas_rep *mr)
}
}
- if (mr_cell) {
- LOGP(DHO, LOGL_INFO, "Cell on ARFCN %u is better, starting "
- "handover\n", mr_cell->arfcn);
- return handover_to_arfcn_bsic(mr->lchan, mr_cell->arfcn,
- mr_cell->bsic);
+ if (!mr_cell) {
+ DEBUGPC(DHO, "No better cell\n");
+ return 0;
}
- DEBUGPC(DHO, "No better cell\n");
- return 0;
+ LOGP(DHO, LOGL_INFO, "Cell on ARFCN %u is better: ", mr_cell->arfcn);
+ if (!mr->lchan->ts->trx->bts->network->handover.active) {
+ LOGPC(DHO, LOGL_INFO, "Skipping, Handover disabled\n");
+ return 0;
+ }
+
+ LOGPC(DHO, LOGL_INFO, "Starting handover\n");
+ return handover_to_arfcn_bsic(mr->lchan, mr_cell->arfcn, mr_cell->bsic);
}
static int ho_dec_sig_cb(unsigned int subsys, unsigned int signal,