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/.
Harald Welte gerrit-no-reply at lists.osmocom.orgHarald Welte has submitted this change and it was merged. Change subject: dyn TS: measurement: use correct nr of subslots, rm code dup ...................................................................... dyn TS: measurement: use correct nr of subslots, rm code dup In measurement.c, fix the number of sublots for TCH/F_TCH/H_PDCH, by using ts_subslots() from gsm_data_shared.c. The local dup of subslots_per_pchan[] is no longer needed. (depends on recent commit to openbsc.git for ts_sublots()) Change-Id: I9d9df470c49487bffd56dde42c7bec0da2f50642 --- M src/common/measurement.c 1 file changed, 1 insertion(+), 15 deletions(-) Approvals: Harald Welte: Looks good to me, approved Jenkins Builder: Verified diff --git a/src/common/measurement.c b/src/common/measurement.c index d0b84d5..be1d4f6 100644 --- a/src/common/measurement.c +++ b/src/common/measurement.c @@ -200,24 +200,10 @@ return 1; } -/* Copied from OpenBSC and enlarged to _GSM_PCHAN_MAX */ -static const uint8_t subslots_per_pchan[_GSM_PCHAN_MAX] = { - [GSM_PCHAN_NONE] = 0, - [GSM_PCHAN_CCCH] = 0, - [GSM_PCHAN_CCCH_SDCCH4] = 4, - [GSM_PCHAN_CCCH_SDCCH4_CBCH] = 4, - [GSM_PCHAN_TCH_F] = 1, - [GSM_PCHAN_TCH_H] = 2, - [GSM_PCHAN_SDCCH8_SACCH8C] = 8, - [GSM_PCHAN_SDCCH8_SACCH8C_CBCH] = 8, - [GSM_PCHAN_TCH_F_PDCH] = 1, - /* dynamic pchan are handled outside of this array */ -}; - static int ts_meas_check_compute(struct gsm_bts_trx_ts *ts, uint32_t fn) { int i; - const int num_subslots = subslots_per_pchan[ts->pchan]; + const int num_subslots = ts_subslots(ts); for (i = 0; i < num_subslots; ++i) { struct gsm_lchan *lchan = &ts->lchan[i]; -- To view, visit https://gerrit.osmocom.org/675 To unsubscribe, visit https://gerrit.osmocom.org/settings Gerrit-MessageType: merged Gerrit-Change-Id: I9d9df470c49487bffd56dde42c7bec0da2f50642 Gerrit-PatchSet: 4 Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de> Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de> Gerrit-Reviewer: neels_test_account <neels at hofmeyr.de>