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


Change subject: osmo-bts-trx/trx_if.c: rename and clarify TRX_MAX_BURST_LEN
......................................................................

osmo-bts-trx/trx_if.c: rename and clarify TRX_MAX_BURST_LEN

This constant actually defines the maximum TRXD message length,
which includes the header and burst bits, not just burst.

Change-Id: I383125e1c4df039fc6b554833bc8736deacbe731
---
M src/osmo-bts-trx/trx_if.c
1 file changed, 5 insertions(+), 4 deletions(-)



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

diff --git a/src/osmo-bts-trx/trx_if.c b/src/osmo-bts-trx/trx_if.c
index 0becdd5..9b1604c 100644
--- a/src/osmo-bts-trx/trx_if.c
+++ b/src/osmo-bts-trx/trx_if.c
@@ -52,8 +52,6 @@

 int transceiver_available = 0;

-#define TRX_MAX_BURST_LEN      512
-
 /*
  * socket helper functions
  */
@@ -587,10 +585,13 @@
  * TRX burst data socket
  */

+/* Maximum DATA message length (header + burst) */
+#define TRX_DATA_MSG_MAX_LEN   512
+
 static int trx_data_read_cb(struct osmo_fd *ofd, unsigned int what)
 {
        struct trx_l1h *l1h = ofd->data;
-       uint8_t buf[TRX_MAX_BURST_LEN];
+       uint8_t buf[TRX_DATA_MSG_MAX_LEN];
        int len;
        uint8_t tn;
        int8_t rssi;
@@ -661,7 +662,7 @@
 int trx_if_send_burst(struct trx_l1h *l1h, uint8_t tn, uint32_t fn, uint8_t 
pwr,
        const ubit_t *bits, uint16_t nbits)
 {
-       uint8_t buf[TRX_MAX_BURST_LEN];
+       uint8_t buf[TRX_DATA_MSG_MAX_LEN];

        if ((nbits != GSM_BURST_LEN) && (nbits != EGPRS_BURST_LEN)) {
                LOGPPHI(l1h->phy_inst, DTRX, LOGL_ERROR, "Tx burst length %u 
invalid\n", nbits);

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

Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Change-Id: I383125e1c4df039fc6b554833bc8736deacbe731
Gerrit-Change-Number: 14610
Gerrit-PatchSet: 1
Gerrit-Owner: fixeria <[email protected]>
Gerrit-MessageType: newchange

Reply via email to