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/.
pespin gerrit-no-reply at lists.osmocom.orgpespin has submitted this change. ( https://gerrit.osmocom.org/c/osmo-pcu/+/22436 ) Change subject: sched: Avoid picking TBF with nacked dl blocks when GMSK is required ...................................................................... sched: Avoid picking TBF with nacked dl blocks when GMSK is required Sine we don't yet implement properly all resegmentation of blocks from same MCS family type, when requiring a GMSK DL block (due to GPRS+EGPRS multiplexing limitations) we need to skip retransmitions, otherwise we'd be incorrectly picking a DL block which was already built with a potentially higher MCS value. The "DL_PRIO_NEW_DATA" prio serves two purposes: * There's new data to send * There's some nacked data to be retransmitted The 2nd purpose has, later on, more priority over the 1st one when the tbf is selected (see gprs_rlcmac_dl_tbf::take_next_bsn()). Until now we were handling correctly the case where the tbf was skipped in case the prio was to resend unacked data (DL_PRIO_SENT_DATA), but was incorrectly selected when it'd send nacked data. Let's fix it by specifically checking w->resend_needed() < 0. Change-Id: I253de8e1a190a9adb56160f38892c9e43e2c0272 --- M src/gprs_rlcmac_sched.cpp 1 file changed, 28 insertions(+), 3 deletions(-) Approvals: pespin: Looks good to me, approved Jenkins Builder: Verified diff --git a/src/gprs_rlcmac_sched.cpp b/src/gprs_rlcmac_sched.cpp index 49a8ff2..6dea949 100644 --- a/src/gprs_rlcmac_sched.cpp +++ b/src/gprs_rlcmac_sched.cpp @@ -275,6 +275,31 @@ return DL_PRIO_NONE; } +/* Check if next data block of a TBF can be encoded in GMSK [(M)CS1-4]. */ +static bool can_produce_gmsk_data_block_next(struct gprs_rlcmac_dl_tbf *tbf, enum tbf_dl_prio prio) +{ + const gprs_rlc_dl_window *w; + + /* GPRS TBFs can always send GMSK */ + if (!tbf->is_egprs_enabled()) + return true; + + switch (prio) { + case DL_PRIO_CONTROL: + /* Control blocks are always CS-1 */ + return true; + case DL_PRIO_NEW_DATA: + /* We can send any new data (no block generated yet) using any + * MCS. However, we don't (yet) support resegmenting already + * sent blocks (NACKed blocks in this case) into lower MCS of + * the same family. See OS#4966 */ + w = static_cast<gprs_rlc_dl_window *>(tbf->window()); + return w->resend_needed() < 0; + default: + return false; + } +} + static struct msgb *sched_select_downlink(struct gprs_rlcmac_bts *bts, uint8_t trx, uint8_t ts, uint32_t fn, uint8_t block_nr, struct gprs_rlcmac_pdch *pdch, enum mcs_kind req_mcs_kind, bool *is_egprs) @@ -319,9 +344,9 @@ /* If a GPRS (CS1-4/MCS1-4) Dl block is required, downgrade MCS * below instead of skipping. However, downgrade can only be * done on new data BSNs (not yet sent) and control blocks. */ - if (req_mcs_kind == EGPRS_GMSK && tbf->is_egprs_enabled() && - (prio !=DL_PRIO_CONTROL && prio != DL_PRIO_NEW_DATA)) { - LOGP(DRLCMACSCHED, LOGL_DEBUG, "Cannot downgrade EGPRS TBF with prio %d\n", prio); + if (req_mcs_kind == EGPRS_GMSK && !can_produce_gmsk_data_block_next(tbf, prio)) { + LOGP(DRLCMACSCHED, LOGL_DEBUG, "%s Cannot downgrade EGPRS TBF with prio %d\n", + tbf_name(tbf), prio); continue; } -- To view, visit https://gerrit.osmocom.org/c/osmo-pcu/+/22436 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: osmo-pcu Gerrit-Branch: master Gerrit-Change-Id: I253de8e1a190a9adb56160f38892c9e43e2c0272 Gerrit-Change-Number: 22436 Gerrit-PatchSet: 3 Gerrit-Owner: pespin <pespin at sysmocom.de> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge at osmocom.org> Gerrit-Reviewer: osmith <osmith at sysmocom.de> Gerrit-Reviewer: pespin <pespin at sysmocom.de> Gerrit-MessageType: merged -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20210126/3c5c9e69/attachment.htm>