<p>pespin has uploaded this change for <strong>review</strong>.</p><p><a href="https://gerrit.osmocom.org/c/osmo-pcu/+/22436">View Change</a></p><pre style="font-family: monospace,monospace; white-space: pre-wrap;">sched: Avoid picking TBF with nacked dl blocks when GMSK is required<br><br>Sine we don't yet implement properly all resegmentation of blocks from<br>same MCS family type, when requiring a GMSK DL block (due to GPRS+EGPRS<br>multiplexing limitations) we need to skip retransmitions, otherwise we'd<br>be incorrectly picking a DL block which was already built with a<br>potentially higher MCS value.<br><br>The "DL_PRIO_NEW_DATA" prio serves two purposes:<br>* There's new data to send<br>* There's some nacked data to be retransmitted<br><br>The later has later on priority when the tbf is selected (see<br>gprs_rlcmac_dl_tbf::take_next_bsn()).<br><br>Until now we were handling correctly the case where the tbf was skipped<br>in case the prio was to resend unacked data (DL_PRIO_SENT_DATA), but<br>was incorrectly selected when it'd send nacked data. Let's fix it by<br>specifically checking w->resend_needed() < 0.<br><br>Change-Id: I253de8e1a190a9adb56160f38892c9e43e2c0272<br>---<br>M src/gprs_rlcmac_sched.cpp<br>1 file changed, 3 insertions(+), 1 deletion(-)<br><br></pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;">git pull ssh://gerrit.osmocom.org:29418/osmo-pcu refs/changes/36/22436/1</pre><pre style="font-family: monospace,monospace; white-space: pre-wrap;"><span>diff --git a/src/gprs_rlcmac_sched.cpp b/src/gprs_rlcmac_sched.cpp</span><br><span>index 49a8ff2..8404456 100644</span><br><span>--- a/src/gprs_rlcmac_sched.cpp</span><br><span>+++ b/src/gprs_rlcmac_sched.cpp</span><br><span>@@ -282,6 +282,7 @@</span><br><span>  struct msgb *msg = NULL;</span><br><span>     struct gprs_rlcmac_dl_tbf *tbf, *prio_tbf = NULL;</span><br><span>    enum tbf_dl_prio prio, max_prio = DL_PRIO_NONE;</span><br><span style="color: hsl(120, 100%, 40%);">+       const gprs_rlc_dl_window *w;</span><br><span> </span><br><span>     uint8_t i, tfi, prio_tfi;</span><br><span>    int age;</span><br><span>@@ -319,8 +320,9 @@</span><br><span>               /* If a GPRS (CS1-4/MCS1-4) Dl block is required, downgrade MCS</span><br><span>               * below instead of skipping. However, downgrade can only be</span><br><span>                  * done on new data BSNs (not yet sent) and control blocks. */</span><br><span style="color: hsl(120, 100%, 40%);">+                w = static_cast<gprs_rlc_dl_window *>(tbf->window());</span><br><span>               if (req_mcs_kind == EGPRS_GMSK && tbf->is_egprs_enabled() &&</span><br><span style="color: hsl(0, 100%, 40%);">-             (prio !=DL_PRIO_CONTROL && prio != DL_PRIO_NEW_DATA)) {</span><br><span style="color: hsl(120, 100%, 40%);">+               (prio !=DL_PRIO_CONTROL && !(prio == DL_PRIO_NEW_DATA && w->resend_needed() < 0))) {</span><br><span>                       LOGP(DRLCMACSCHED, LOGL_DEBUG, "Cannot downgrade EGPRS TBF with prio %d\n", prio);</span><br><span>                         continue;</span><br><span>            }</span><br><span></span><br></pre><p>To view, visit <a href="https://gerrit.osmocom.org/c/osmo-pcu/+/22436">change 22436</a>. To unsubscribe, or for help writing mail filters, visit <a href="https://gerrit.osmocom.org/settings">settings</a>.</p><div itemscope itemtype="http://schema.org/EmailMessage"><div itemscope itemprop="action" itemtype="http://schema.org/ViewAction"><link itemprop="url" href="https://gerrit.osmocom.org/c/osmo-pcu/+/22436"/><meta itemprop="name" content="View Change"/></div></div>

<div style="display:none"> Gerrit-Project: osmo-pcu </div>
<div style="display:none"> Gerrit-Branch: master </div>
<div style="display:none"> Gerrit-Change-Id: I253de8e1a190a9adb56160f38892c9e43e2c0272 </div>
<div style="display:none"> Gerrit-Change-Number: 22436 </div>
<div style="display:none"> Gerrit-PatchSet: 1 </div>
<div style="display:none"> Gerrit-Owner: pespin <pespin@sysmocom.de> </div>
<div style="display:none"> Gerrit-MessageType: newchange </div>