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/.
pespin gerrit-no-reply at lists.osmocom.orgpespin has submitted this change and it was merged. ( https://gerrit.osmocom.org/c/osmo-trx/+/14897 )
Change subject: Transceiver: Store TRXD version per channel
......................................................................
Transceiver: Store TRXD version per channel
The setting is negotiatied by osmo-bts-trx on each channel, so let's
keep and use state per channel instead of overwriting the state from
different channels.
Take the chance to change related log lines to also print the channel
number.
Change-Id: If9cf95e89d38d0155ab48b8c0977ca5f381c2aad
---
M Transceiver52M/Transceiver.cpp
M Transceiver52M/Transceiver.h
2 files changed, 9 insertions(+), 8 deletions(-)
Approvals:
laforge: Looks good to me, but someone else must approve
fixeria: Looks good to me, but someone else must approve
pespin: Looks good to me, approved
Jenkins Builder: Verified
diff --git a/Transceiver52M/Transceiver.cpp b/Transceiver52M/Transceiver.cpp
index af6b0dd..a47f7db 100644
--- a/Transceiver52M/Transceiver.cpp
+++ b/Transceiver52M/Transceiver.cpp
@@ -129,7 +129,7 @@
mSPSTx(tx_sps), mSPSRx(rx_sps), mChans(chans), mExtRACH(false), mEdge(false),
mOn(false), mForceClockInterface(false),
mTxFreq(0.0), mRxFreq(0.0), mTSC(0), mMaxExpectedDelayAB(0), mMaxExpectedDelayNB(0),
- mWriteBurstToDiskMask(0), mVersionTRXD(0)
+ mWriteBurstToDiskMask(0)
{
txFullScale = mRadioInterface->fullScaleInputValue();
rxFullScale = mRadioInterface->fullScaleOutputValue();
@@ -198,6 +198,7 @@
mTxPriorityQueues.resize(mChans);
mReceiveFIFO.resize(mChans);
mStates.resize(mChans);
+ mVersionTRXD.resize(mChans);
/* Filler table retransmissions - support only on channel 0 */
if (filler == FILLER_DUMMY)
@@ -885,14 +886,14 @@
// set TRXD protocol version
unsigned version_recv;
sscanf(params, "%u", &version_recv);
- LOGC(DTRXCTRL, INFO) << "BTS requests TRXD version switch: " << version_recv;
+ LOGCHAN(chan, DTRXCTRL, INFO) << "BTS requests TRXD version switch: " << version_recv;
if (version_recv > TRX_DATA_FORMAT_VER) {
- LOGC(DTRXCTRL, INFO) << "rejecting TRXD version " << version_recv
- << "in favor of " << TRX_DATA_FORMAT_VER;
+ LOGCHAN(chan, DTRXCTRL, INFO) << "rejecting TRXD version " << version_recv
+ << "in favor of " << TRX_DATA_FORMAT_VER;
sprintf(response, "RSP SETFORMAT %u %u", TRX_DATA_FORMAT_VER, version_recv);
} else {
- LOGC(DTRXCTRL, NOTICE) << "switching to TRXD version " << version_recv;
- mVersionTRXD = version_recv;
+ LOGCHAN(chan, DTRXCTRL, NOTICE) << "switching to TRXD version " << version_recv;
+ mVersionTRXD[chan] = version_recv;
sprintf(response, "RSP SETFORMAT %u %u", version_recv, version_recv);
}
} else if (match_cmd(command, "_SETBURSTTODISKMASK", ¶ms)) {
@@ -1023,7 +1024,7 @@
if (!bi.idle)
logRxBurst(chan, &bi);
- switch (mVersionTRXD) {
+ switch (mVersionTRXD[chan]) {
case 0:
trxd_send_burst_ind_v0(chan, mDataSockets[chan], &bi);
break;
diff --git a/Transceiver52M/Transceiver.h b/Transceiver52M/Transceiver.h
index 8b5a9b1..8da52d1 100644
--- a/Transceiver52M/Transceiver.h
+++ b/Transceiver52M/Transceiver.h
@@ -218,8 +218,8 @@
unsigned mMaxExpectedDelayAB; ///< maximum expected time-of-arrival offset in GSM symbols for Access Bursts (RACH)
unsigned mMaxExpectedDelayNB; ///< maximum expected time-of-arrival offset in GSM symbols for Normal Bursts
unsigned mWriteBurstToDiskMask; ///< debug: bitmask to indicate which timeslots to dump to disk
- unsigned mVersionTRXD; ///< Format version to use for TRXD protocol communication
+ std::vector<unsigned> mVersionTRXD; ///< Format version to use for TRXD protocol communication, per channel
std::vector<TransceiverState> mStates;
/** Start and stop I/O threads through the control socket API */
--
To view, visit https://gerrit.osmocom.org/c/osmo-trx/+/14897
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-trx
Gerrit-Branch: master
Gerrit-Change-Id: If9cf95e89d38d0155ab48b8c0977ca5f381c2aad
Gerrit-Change-Number: 14897
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <axilirator at gmail.com>
Gerrit-Reviewer: laforge <laforge at gnumonks.org>
Gerrit-Reviewer: pespin <pespin at sysmocom.de>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20190723/246806cf/attachment.htm>