mirror of https://github.com/PentHertz/srsLTE.git
rlc_am: fix potential stalling in RLC transmitter
it turned out that a certain order of events can lead to a RLC transmitter stalling because even though unacknowledged PDUs are queued, none of them was actually considered for retx. This can happen if a pollRetxTimer expires for a SN that, meanwhile, has already been acknowledged. The positive lead to the deletion of the SN from the Tx window. The fix makes sure that when a retx for a unexisting SN is requested, the sender will consider the next unacknowledged SN instead.
This commit is contained in:
parent
9612bb0e14
commit
f22f4b4fbd
|
@ -701,8 +701,15 @@ int rlc_am_lte::rlc_am_lte_tx::build_retx_pdu(uint8_t* payload, uint32_t nof_byt
|
||||||
if (!retx_queue.empty()) {
|
if (!retx_queue.empty()) {
|
||||||
retx = retx_queue.front();
|
retx = retx_queue.front();
|
||||||
} else {
|
} else {
|
||||||
logger.info("In build_retx_pdu(): retx_queue is empty during sanity check, sn=%d", retx.sn);
|
logger.info("%s SN=%d not in Tx window. Ignoring retx.", RB_NAME, retx.sn);
|
||||||
return 0;
|
if (tx_window.has_sn(vt_a)) {
|
||||||
|
// schedule next SN for retx
|
||||||
|
retransmit_pdu(vt_a);
|
||||||
|
retx = retx_queue.front();
|
||||||
|
} else {
|
||||||
|
// empty tx window, can't provide retx PDU
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue