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.orgfixeria has uploaded this change for review. ( https://gerrit.osmocom.org/c/osmo-bts/+/25734 ) Change subject: gsm_lchan_interf_meas_calc_avg(): adapt to the ordering of boundaries ...................................................................... gsm_lchan_interf_meas_calc_avg(): adapt to the ordering of boundaries Change-Id: I88d841d8d835bde8392c7b606b28c9070b7adc6e Related: SYS#5313 --- M src/common/lchan.c 1 file changed, 12 insertions(+), 4 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/34/25734/1 diff --git a/src/common/lchan.c b/src/common/lchan.c index f7ee33b..af408a5 100644 --- a/src/common/lchan.c +++ b/src/common/lchan.c @@ -366,10 +366,18 @@ /* Calculate the average of all collected samples */ meas_avg = meas_sum / (int) meas_num; - /* Determine the band using interference boundaries from BSC */ - for (b = 0; b < ARRAY_SIZE(bts->interference.boundary); b++) { - if (meas_avg >= bts->interference.boundary[b]) - break; /* Current 'b' is the band value */ + /* Determine the band using interference boundaries from BSC + * FIXME: maybe rather inverse bts->interference.boundary in oml.c? */ + if (bts->interference.boundary[0] >= bts->interference.boundary[1]) { + for (b = 0; b < ARRAY_SIZE(bts->interference.boundary); b++) { + if (meas_avg >= bts->interference.boundary[b]) + break; /* Current 'b' is the band value */ + } + } else { + for (b = 0; b < ARRAY_SIZE(bts->interference.boundary); b++) { + if (meas_avg >= bts->interference.boundary[b]) + break; /* Current 'b' is the band value */ + } } LOGPLCHAN(lchan, DL1C, LOGL_DEBUG, -- To view, visit https://gerrit.osmocom.org/c/osmo-bts/+/25734 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Change-Id: I88d841d8d835bde8392c7b606b28c9070b7adc6e Gerrit-Change-Number: 25734 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/20211008/be41e0dd/attachment.htm>