Hello Max, Neels Hofmeyr, Harald Welte, Jenkins Builder,

I'd like you to reexamine a change.  Please visit

    https://gerrit.osmocom.org/2813

to look at the new patch set (#5).

osmo-bts-trx: fix missing frame number in MEAS IND

The layer 1 interface (l1_if.c) for osmo-bts-trx does not include
the frame number into the measurement indications it forwards
to higher layers. The frame number is required to properly
detect the end of a measurement period.

Change-Id: Ife3c791ff50e8a866a97b9783ac7ef3ef2402a70
---
M src/osmo-bts-trx/l1_if.c
M src/osmo-bts-trx/l1_if.h
2 files changed, 4 insertions(+), 3 deletions(-)


  git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/13/2813/5

diff --git a/src/osmo-bts-trx/l1_if.c b/src/osmo-bts-trx/l1_if.c
index a7bcd2c..3517787 100644
--- a/src/osmo-bts-trx/l1_if.c
+++ b/src/osmo-bts-trx/l1_if.c
@@ -528,7 +528,7 @@
 
 
 void l1if_fill_meas_res(struct osmo_phsap_prim *l1sap, uint8_t chan_nr, float 
ta,
-       float ber, float rssi)
+       float ber, float rssi, uint32_t fn)
 {
        memset(l1sap, 0, sizeof(*l1sap));
        osmo_prim_init(&l1sap->oph, SAP_GSM_PH, PRIM_MPH_INFO,
@@ -538,6 +538,7 @@
        l1sap->u.info.u.meas_ind.ta_offs_qbits = (int16_t)(ta*4);
        l1sap->u.info.u.meas_ind.ber10k = (unsigned int) (ber * 10000);
        l1sap->u.info.u.meas_ind.inv_rssi = (uint8_t) (rssi * -1);
+       l1sap->u.info.u.meas_ind.fn = fn;
 }
 
 int l1if_process_meas_res(struct gsm_bts_trx *trx, uint8_t tn, uint32_t fn, 
uint8_t chan_nr,
@@ -553,7 +554,7 @@
                gsm_lchan_name(lchan), fn, chan_nr, 
ms_pwr_dbm(lchan->ts->trx->bts->band, lchan->ms_power),
                rssi, ber*100, n_errors, n_bits_total, lchan->meas.l1_info[1], 
lchan->rqd_ta, toa);
 
-       l1if_fill_meas_res(&l1sap, chan_nr, lchan->rqd_ta + toa, ber, rssi);
+       l1if_fill_meas_res(&l1sap, chan_nr, lchan->rqd_ta + toa, ber, rssi, fn);
 
        return l1sap_up(trx, &l1sap);
 }
diff --git a/src/osmo-bts-trx/l1_if.h b/src/osmo-bts-trx/l1_if.h
index 1864857..fdc40f2 100644
--- a/src/osmo-bts-trx/l1_if.h
+++ b/src/osmo-bts-trx/l1_if.h
@@ -69,7 +69,7 @@
 int l1if_provision_transceiver(struct gsm_bts *bts);
 int l1if_mph_time_ind(struct gsm_bts *bts, uint32_t fn);
 void l1if_fill_meas_res(struct osmo_phsap_prim *l1sap, uint8_t chan_nr, float 
ta,
-       float ber, float rssi);
+       float ber, float rssi, uint32_t fn);
 int l1if_process_meas_res(struct gsm_bts_trx *trx, uint8_t tn, uint32_t fn, 
uint8_t chan_nr,
        int n_errors, int n_bits_total, float rssi, float toa);
 

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

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Ife3c791ff50e8a866a97b9783ac7ef3ef2402a70
Gerrit-PatchSet: 5
Gerrit-Project: osmo-bts
Gerrit-Branch: master
Gerrit-Owner: dexter <pma...@sysmocom.de>
Gerrit-Reviewer: Harald Welte <lafo...@gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Max <msur...@sysmocom.de>
Gerrit-Reviewer: Neels Hofmeyr <nhofm...@sysmocom.de>

Reply via email to