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.orgReview at https://gerrit.osmocom.org/2751 rx_tchh_fn(): Avoid copy+pasting formula to determine odd-ness of fn Change-Id: Ic2a0bdaa70cc28c1ce8237351b0a0c6b998cf0a3 --- M src/osmo-bts-trx/scheduler_trx.c 1 file changed, 7 insertions(+), 4 deletions(-) git pull ssh://gerrit.osmocom.org:29418/osmo-bts refs/changes/51/2751/1 diff --git a/src/osmo-bts-trx/scheduler_trx.c b/src/osmo-bts-trx/scheduler_trx.c index ae2bba4..9ec9592 100644 --- a/src/osmo-bts-trx/scheduler_trx.c +++ b/src/osmo-bts-trx/scheduler_trx.c @@ -1197,6 +1197,11 @@ int n_errors, n_bits_total; struct gsm_lchan *lchan = get_lchan_by_chan_nr(l1t->trx, trx_chan_desc[chan].chan_nr | tn); + /* Note on FN-10: If we are at FN 10, we decoded an even aligned + * TCH/FACCH frame, because our burst buffer carries 6 bursts. + * Even FN ending at: 10,11,19,20,2,3 + */ + int fn_is_odd = (((fn + 26 - 10) % 26) >> 2) & 1; /* handle RACH, if handover RACH detection is turned on */ if (chan_state->ho_rach_detect == 1) @@ -1257,8 +1262,7 @@ * Even FN ending at: 10,11,19,20,2,3 */ rc = gsm0503_tch_hr_decode(tch_data, *bursts_p, - (((fn + 26 - 10) % 26) >> 2) & 1, - &n_errors, &n_bits_total); + fn_is_odd, &n_errors, &n_bits_total); if (rc) /* DTXu */ lchan_set_marker(osmo_hr_check_sid(tch_data, rc), lchan); break; @@ -1268,8 +1272,7 @@ * is included in frame. */ rc = gsm0503_tch_ahs_decode(tch_data + 2, *bursts_p, - (((fn + 26 - 10) % 26) >> 2) & 1, - (((fn + 26 - 10) % 26) >> 2) & 1, chan_state->codec, + fn_is_odd, fn_is_odd, chan_state->codec, chan_state->codecs, &chan_state->ul_ft, &chan_state->ul_cmr, &n_errors, &n_bits_total); if (rc) -- To view, visit https://gerrit.osmocom.org/2751 To unsubscribe, visit https://gerrit.osmocom.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ic2a0bdaa70cc28c1ce8237351b0a0c6b998cf0a3 Gerrit-PatchSet: 1 Gerrit-Project: osmo-bts Gerrit-Branch: master Gerrit-Owner: Harald Welte <laforge at gnumonks.org>