[PATCH] osmo-bts[master]: dyn PDCH: complete for trx: implement bts_model_ts_[dis]conn...

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Neels Hofmeyr gerrit-no-reply at lists.osmocom.org
Thu Jul 28 16:37:06 UTC 2016


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

dyn PDCH: complete for trx: implement bts_model_ts_[dis]connect()

bts_model_ts_disconnect() has nothing to do.

bts_model_ts_connect() merely sets the new pchan on the ts.

Change-Id: Ieb66935d6efc26854e95d238e810c4f8b16cfa88
---
M src/osmo-bts-trx/l1_if.c
1 file changed, 17 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/28/628/1

diff --git a/src/osmo-bts-trx/l1_if.c b/src/osmo-bts-trx/l1_if.c
index 21627eb..fcc3d54 100644
--- a/src/osmo-bts-trx/l1_if.c
+++ b/src/osmo-bts-trx/l1_if.c
@@ -753,11 +753,26 @@
 
 int bts_model_ts_disconnect(struct gsm_bts_trx_ts *ts)
 {
-	return -ENOTSUP;
+	/* no action required, signal completion right away. */
+	cb_ts_disconnected(ts);
+	return 0;
 }
 
 int bts_model_ts_connect(struct gsm_bts_trx_ts *ts,
 			 enum gsm_phys_chan_config as_pchan)
 {
-	return -ENOTSUP;
+	int rc;
+	LOGP(DL1C, LOGL_DEBUG, "%s bts_model_ts_connect(as_pchan=%s)\n",
+	     gsm_ts_name(ts), gsm_pchan_name(as_pchan));
+
+	rc = trx_set_ts_as_pchan(ts, as_pchan);
+	if (rc)
+		return rc;
+
+	LOGP(DL1C, LOGL_NOTICE, "%s bts_model_ts_connect(as_pchan=%s) success,"
+	     " calling cb_ts_connected()\n",
+	     gsm_ts_name(ts), gsm_pchan_name(as_pchan));
+
+	cb_ts_connected(ts);
+	return 0;
 }

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ieb66935d6efc26854e95d238e810c4f8b16cfa88
Gerrit-PatchSet: 1
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: neels_test_account <neels at hofmeyr.de>



More information about the gerrit-log mailing list