[PATCH] osmocom-bb[master]: host/trxcon/l1ctl.c: retune TRX only if current ARFCN differs

Harald Welte gerrit-no-reply at lists.osmocom.org
Thu Feb 22 15:33:21 UTC 2018


Review at  https://gerrit.osmocom.org/6772

host/trxcon/l1ctl.c: retune TRX only if current ARFCN differs

Change-Id: I797dc284bd92d07ad4859f851a44d048407db86d
---
M src/host/trxcon/l1ctl.c
1 file changed, 9 insertions(+), 5 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmocom-bb refs/changes/72/6772/1

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 @@
 	/* 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 */

-- 
To view, visit https://gerrit.osmocom.org/6772
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I797dc284bd92d07ad4859f851a44d048407db86d
Gerrit-PatchSet: 1
Gerrit-Project: osmocom-bb
Gerrit-Branch: master
Gerrit-Owner: Harald Welte <laforge at gnumonks.org>


More information about the gerrit-log mailing list