Change in osmo-bts[master]: osmo-bts-trx: assert PDU version in trx_if_send_burst()

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

fixeria gerrit-no-reply at lists.osmocom.org
Thu Apr 22 15:25:33 UTC 2021


fixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bts/+/23866 )


Change subject: osmo-bts-trx: assert PDU version in trx_if_send_burst()
......................................................................

osmo-bts-trx: assert PDU version in trx_if_send_burst()

If somehow the TRXC logic negotiates a non-supported TRXD PDU version,
then it's a serious bug in the code.  Let's add an assert() for that.

Change-Id: I301377bcebd5e2bbcfc18b3637253ef261bb5b2e
---
M src/osmo-bts-trx/trx_if.c
1 file changed, 2 insertions(+), 3 deletions(-)



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

diff --git a/src/osmo-bts-trx/trx_if.c b/src/osmo-bts-trx/trx_if.c
index 30c74dd..9ea16ca 100644
--- a/src/osmo-bts-trx/trx_if.c
+++ b/src/osmo-bts-trx/trx_if.c
@@ -1018,9 +1018,8 @@
 		break;
 
 	default:
-		LOGPPHI(l1h->phy_inst, DTRX, LOGL_ERROR,
-			"Requested TRXD PDU version %u is not supported\n", pdu_ver);
-		return -ENOTSUP;
+		/* Shall not happen */
+		OSMO_ASSERT(0);
 	}
 
 	ptr[0] = ((pdu_ver & 0x0f) << 4) | br->tn;

-- 
To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/23866
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I301377bcebd5e2bbcfc18b3637253ef261bb5b2e
Gerrit-Change-Number: 23866
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <vyanitskiy at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210422/eec77760/attachment.htm>


More information about the gerrit-log mailing list