pespin submitted this change.

View Change


Approvals: fixeria: Looks good to me, approved; Verified Jenkins Builder: Verified
rlcmac: tbf_ul_ass_fsm: Fix logic delay starting time

The previous logic was wrongly written. We want:
* If PKT UL ASS didn't have a tbf_starting_time but had an S/P+RRBP,
it means we have to delay completing the FSM until we send the PKT CTRL ACK (next_blk)
* If it contained tbf_starting_time, if it happens before next_blk, still wait until next_blk

Change-Id: I60cdc0315e28f71843c51eba88acc78780c6ab43
---
M src/rlcmac/tbf_ul_ass_fsm.c
1 file changed, 16 insertions(+), 2 deletions(-)

diff --git a/src/rlcmac/tbf_ul_ass_fsm.c b/src/rlcmac/tbf_ul_ass_fsm.c
index 1783d5b..1c67213 100644
--- a/src/rlcmac/tbf_ul_ass_fsm.c
+++ b/src/rlcmac/tbf_ul_ass_fsm.c
@@ -413,7 +413,7 @@
/* We need to wait at least until sending the PKT CTRL
* ACK (in the old CTRL TS) before completing the
* assignment and using the new TS assignment. */
- if (!ctx->tbf_starting_time_exists && gsm0502_fncmp(ctx->tbf_starting_time, next_blk) < 0) {
+ if (!ctx->tbf_starting_time_exists || gsm0502_fncmp(ctx->tbf_starting_time, next_blk) < 0) {
ctx->tbf_starting_time_exists = true;
ctx->tbf_starting_time = next_blk;
}
@@ -474,7 +474,7 @@
/* We need to wait at least until sending the PKT CTRL
* ACK (in the old CTRL TS) before completing the
* assignment and using the new TS assignment. */
- if (!ctx->tbf_starting_time_exists && gsm0502_fncmp(ctx->tbf_starting_time, next_blk) < 0) {
+ if (!ctx->tbf_starting_time_exists || gsm0502_fncmp(ctx->tbf_starting_time, next_blk) < 0) {
ctx->tbf_starting_time_exists = true;
ctx->tbf_starting_time = next_blk;
}

To view, visit change 34667. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: libosmo-gprs
Gerrit-Branch: master
Gerrit-Change-Id: I60cdc0315e28f71843c51eba88acc78780c6ab43
Gerrit-Change-Number: 34667
Gerrit-PatchSet: 2
Gerrit-Owner: pespin <pespin@sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: fixeria <vyanitskiy@sysmocom.de>
Gerrit-Reviewer: pespin <pespin@sysmocom.de>
Gerrit-MessageType: merged