Change in osmo-trx[master]: lms: fix LMS_StartStream() handling for multiple channels

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/.

Harald Welte gerrit-no-reply at lists.osmocom.org
Wed Jun 13 21:33:35 UTC 2018


Harald Welte has uploaded this change for review. ( https://gerrit.osmocom.org/9616


Change subject: lms: fix LMS_StartStream() handling for multiple channels
......................................................................

lms: fix LMS_StartStream() handling for multiple channels

LMS_StartStream() (in LMSDevice::start()) was moved to separate loop. It
is because LMS_SetupStream() would fail for second channel if streaming
has already been started (LMS_StartStream()) for single channel
configuration.

Change-Id: I6704bb92864aa81417507c4ae24a22f41dc529c1
---
M Transceiver52M/device/lms/LMSDevice.cpp
1 file changed, 5 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/osmo-trx refs/changes/16/9616/1

diff --git a/Transceiver52M/device/lms/LMSDevice.cpp b/Transceiver52M/device/lms/LMSDevice.cpp
index 9c74c0a..ad6f67b 100644
--- a/Transceiver52M/device/lms/LMSDevice.cpp
+++ b/Transceiver52M/device/lms/LMSDevice.cpp
@@ -205,6 +205,7 @@
 
 	unsigned int i;
 
+	/* configure the channels/streams */
 	for (i=0; i<chans; i++) {
 		if (LMS_EnableChannel(m_lms_dev, LMS_CH_RX, i, true) < 0)
 			return false;
@@ -235,7 +236,11 @@
 
 		if (LMS_SetupStream(m_lms_dev, &m_lms_stream_tx[i]) < 0)
 			return false;
+	}
 
+	/* now start the streams in a second loop, as we can no longer call
+	 * LMS_SetupStream() after LMS_StartStream() of the first stream */
+	for (i = 0; i < chans; i++) {
 		if (LMS_StartStream(&m_lms_stream_rx[i]) < 0)
 			return false;
 

-- 
To view, visit https://gerrit.osmocom.org/9616
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: I6704bb92864aa81417507c4ae24a22f41dc529c1
Gerrit-Change-Number: 9616
Gerrit-PatchSet: 1
Gerrit-Owner: Harald Welte <laforge at gnumonks.org>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20180613/b27679bb/attachment.htm>


More information about the gerrit-log mailing list