summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVadim Yanitskiy <axilirator@gmail.com>2017-08-07 13:18:59 +0600
committerVadim Yanitskiy <axilirator@gmail.com>2017-10-23 22:05:49 +0330
commit665e1e2baad0aed753d4dc59f27f985414d77b50 (patch)
treea59a5b786894bab28d993accfc9463c751d37836
parent1baca021272f031b9ce4d08c830a174d2740c821 (diff)
host/trxcon/l1ctl.c: retune TRX only if current ARFCN differs
-rw-r--r--src/host/trxcon/l1ctl.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/host/trxcon/l1ctl.c b/src/host/trxcon/l1ctl.c
index 3cf98b3..8f96890 100644
--- a/src/host/trxcon/l1ctl.c
+++ b/src/host/trxcon/l1ctl.c
@@ -306,12 +306,16 @@ static int l1ctl_rx_fbsb_req(struct l1ctl_link *l1l, struct msgb *msg)
/* Ask SCH handler to send L1CTL_FBSB_CONF */
l1l->fbsb_conf_sent = 0;
- /* Store current ARFCN */
- l1l->trx->band_arfcn = band_arfcn;
+ /* Only if current ARFCN differs */
+ if (l1l->trx->band_arfcn != band_arfcn) {
+ /* Update current ARFCN */
+ l1l->trx->band_arfcn = band_arfcn;
+
+ /* Tune transceiver to required ARFCN */
+ trx_if_cmd_rxtune(l1l->trx, band_arfcn);
+ trx_if_cmd_txtune(l1l->trx, band_arfcn);
+ }
- /* Tune transceiver to required ARFCN */
- trx_if_cmd_rxtune(l1l->trx, band_arfcn);
- trx_if_cmd_txtune(l1l->trx, band_arfcn);
trx_if_cmd_poweron(l1l->trx);
/* Start FBSB expire timer */