Change in libosmocore[master]: lapdm: Allow SABM L=0 in Timer Recovery State

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.org
Tue Oct 20 16:47:17 UTC 2020


pespin has uploaded this change for review. ( https://gerrit.osmocom.org/c/libosmocore/+/20807 )


Change subject: lapdm: Allow SABM L=0 in Timer Recovery State
......................................................................

lapdm: Allow SABM L=0 in Timer Recovery State

3GPP TS 44.006 8.6.3 "Procedures for re-establishment" is quite
explicit:
"""
When the data link layer receives in the multiple frame established state
or !!!timer recovery state!!! a DL-ESTABLISH- REQUEST primitive from layer
3 or an SABM (with L=0), the normal establishment procedure of sub-clause
8.4.1.2 shall be initiated.
"""

Related: OS#4549
Related: OS#4819
Change-Id: I7959dc39f883cd5c56c36a21176a2401838d7b62
---
M src/gsm/lapd_core.c
1 file changed, 17 insertions(+), 0 deletions(-)



  git pull ssh://gerrit.osmocom.org:29418/libosmocore refs/changes/07/20807/1

diff --git a/src/gsm/lapd_core.c b/src/gsm/lapd_core.c
index 6a56572..d2cc820 100644
--- a/src/gsm/lapd_core.c
+++ b/src/gsm/lapd_core.c
@@ -852,6 +852,23 @@
 		switch (dl->state) {
 		case LAPD_STATE_IDLE:
 			break;
+		case LAPD_STATE_TIMER_RECOV:
+			LOGDL(dl, LOGL_INFO, "SABM command, timer recovery state\n");
+			/* If link is lost on the remote side, we start over
+			 * and send DL-ESTABLISH indication again. */
+			/* 3GPP TS 44.006 8.6.3 "Procedures for re-establishment" */
+			if (length) {
+				/* check for contention resoultion */
+				LOGDL(dl, LOGL_ERROR, "SABM L>0 not expected in "
+				      "timer recovery state\n");
+				mdl_error(MDL_CAUSE_SABM_INFO_NOTALL, lctx);
+				lapd_send_ua(lctx, length, msg->l3h);
+				msgb_free(msg);
+				return 0;
+			}
+			/* re-establishment, continue below */
+			lapd_stop_t200(dl);
+			break;
 		case LAPD_STATE_MF_EST:
 			LOGDL(dl, LOGL_INFO, "SABM command, multiple frame established state\n");
 			/* If link is lost on the remote side, we start over

-- 
To view, visit https://gerrit.osmocom.org/c/libosmocore/+/20807
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: libosmocore
Gerrit-Branch: master
Gerrit-Change-Id: I7959dc39f883cd5c56c36a21176a2401838d7b62
Gerrit-Change-Number: 20807
Gerrit-PatchSet: 1
Gerrit-Owner: pespin <pespin at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20201020/99efff21/attachment.htm>


More information about the gerrit-log mailing list