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/.
laforge gerrit-no-reply at lists.osmocom.orglaforge has submitted this change. ( https://gerrit.osmocom.org/c/libosmocore/+/22643 ) Change subject: gprs_ns2_vc_fsm: rename ST_ALIVE -> ST_RECOVERING ...................................................................... gprs_ns2_vc_fsm: rename ST_ALIVE -> ST_RECOVERING ST_ALIVE isn't quite clear. This state means this NS-VC is still dead. ST_ALIVE is used for NS-VC with vc_mode ALIVE (e.g. UDP NS-VC). It's the first state when the remote hasn't yet answered or when the NS-VC lost ALIVEs. Related: OS#4958 Change-Id: I0b29e8ce6444546d90bde68b1f957f1013238784 --- M src/gb/gprs_ns2_vc_fsm.c 1 file changed, 17 insertions(+), 17 deletions(-) Approvals: pespin: Looks good to me, but someone else must approve laforge: Looks good to me, approved Jenkins Builder: Verified diff --git a/src/gb/gprs_ns2_vc_fsm.c b/src/gb/gprs_ns2_vc_fsm.c index 6314408..f6424de 100644 --- a/src/gb/gprs_ns2_vc_fsm.c +++ b/src/gb/gprs_ns2_vc_fsm.c @@ -81,13 +81,13 @@ * - UNCONFIGURED -> RESET -> BLOCK -> UNBLOCKED * * Without RESET/BLOCK, the state should follow: - * - UNCONFIGURED -> ALIVE -> UNBLOCKED + * - UNCONFIGURED -> RECOVERY -> UNBLOCKED * * The UNBLOCKED and TEST states are used to send ALIVE PDU using the timeout Tns-test and Tns-alive. * UNBLOCKED -> TEST: on expire of Tns-Test, send Alive PDU. * TEST -> UNBLOCKED: on receive of Alive_Ack PDU, go into UNBLOCKED. * - * The ALIVE state is used as intermediate, because a VC is only valid if it received an Alive ACK when + * The RECOVERY state is used as intermediate, because a VC is only valid if it received an Alive ACK when * not using RESET/BLOCK procedure. */ @@ -97,7 +97,7 @@ GPRS_NS2_ST_BLOCKED, GPRS_NS2_ST_UNBLOCKED, /* allows sending NS_UNITDATA */ - GPRS_NS2_ST_ALIVE, /* only used when not using RESET/BLOCK procedure */ + GPRS_NS2_ST_RECOVERING, /* only used when not using RESET/BLOCK procedure */ }; enum gprs_ns2_vc_event { @@ -217,7 +217,7 @@ if (priv->nsvc->mode == GPRS_NS2_VC_MODE_BLOCKRESET) { osmo_fsm_inst_state_chg(fi, GPRS_NS2_ST_RESET, nsi->timeout[NS_TOUT_TNS_RESET], 0); } else { - osmo_fsm_inst_state_chg(fi, GPRS_NS2_ST_ALIVE, nsi->timeout[NS_TOUT_TNS_ALIVE], 0); + osmo_fsm_inst_state_chg(fi, GPRS_NS2_ST_RECOVERING, nsi->timeout[NS_TOUT_TNS_ALIVE], 0); } } break; @@ -244,7 +244,7 @@ case GPRS_NS2_EV_REQ_START: switch (priv->nsvc->mode) { case GPRS_NS2_VC_MODE_ALIVE: - osmo_fsm_inst_state_chg(fi, GPRS_NS2_ST_ALIVE, nsi->timeout[NS_TOUT_TNS_ALIVE], NS_TOUT_TNS_ALIVE); + osmo_fsm_inst_state_chg(fi, GPRS_NS2_ST_RECOVERING, nsi->timeout[NS_TOUT_TNS_ALIVE], NS_TOUT_TNS_ALIVE); break; case GPRS_NS2_VC_MODE_BLOCKRESET: osmo_fsm_inst_state_chg(fi, GPRS_NS2_ST_RESET, nsi->timeout[NS_TOUT_TNS_RESET], NS_TOUT_TNS_RESET); @@ -422,7 +422,7 @@ priv->alive.mode = NS_TOUT_TNS_TEST; osmo_timer_schedule(&priv->alive.timer, nsi->timeout[NS_TOUT_TNS_TEST], 0); - if (old_state != GPRS_NS2_ST_ALIVE) + if (old_state != GPRS_NS2_ST_RECOVERING) priv->N = 0; ns2_tx_alive(priv->nsvc); @@ -437,7 +437,7 @@ static const struct osmo_fsm_state ns2_vc_states[] = { [GPRS_NS2_ST_UNCONFIGURED] = { .in_event_mask = S(GPRS_NS2_EV_REQ_START), - .out_state_mask = S(GPRS_NS2_ST_RESET) | S(GPRS_NS2_ST_ALIVE), + .out_state_mask = S(GPRS_NS2_ST_RESET) | S(GPRS_NS2_ST_RECOVERING), .name = "UNCONFIGURED", .action = ns2_st_unconfigured, .onenter = ns2_st_unconfigured_onenter, @@ -465,7 +465,7 @@ [GPRS_NS2_ST_UNBLOCKED] = { .in_event_mask = S(GPRS_NS2_EV_RX_BLOCK) | S(GPRS_NS2_EV_RX_UNBLOCK_ACK) | S(GPRS_NS2_EV_RX_UNBLOCK), - .out_state_mask = S(GPRS_NS2_ST_RESET) | S(GPRS_NS2_ST_ALIVE) | + .out_state_mask = S(GPRS_NS2_ST_RESET) | S(GPRS_NS2_ST_RECOVERING) | S(GPRS_NS2_ST_BLOCKED) | S(GPRS_NS2_ST_UNCONFIGURED), .name = "UNBLOCKED", @@ -473,13 +473,13 @@ .onenter = ns2_st_unblocked_on_enter, }, - /* ST_ALIVE is only used on VC without RESET/BLOCK */ - [GPRS_NS2_ST_ALIVE] = { + /* ST_RECOVERING is only used on VC without RESET/BLOCK */ + [GPRS_NS2_ST_RECOVERING] = { .in_event_mask = S(GPRS_NS2_EV_RX_ALIVE_ACK), - .out_state_mask = S(GPRS_NS2_ST_ALIVE) | + .out_state_mask = S(GPRS_NS2_ST_RECOVERING) | S(GPRS_NS2_ST_UNBLOCKED) | S(GPRS_NS2_ST_UNCONFIGURED), - .name = "ALIVE", + .name = "RECOVERING", .action = ns2_st_alive, .onenter = ns2_st_alive_onenter, .onleave = ns2_st_alive_onleave, @@ -523,14 +523,14 @@ } } break; - case GPRS_NS2_ST_ALIVE: + case GPRS_NS2_ST_RECOVERING: if (priv->initiate_reset) { priv->N++; if (priv->N <= nsi->timeout[NS_TOUT_TNS_ALIVE_RETRIES]) { - osmo_fsm_inst_state_chg(fi, GPRS_NS2_ST_ALIVE, 0, 0); + osmo_fsm_inst_state_chg(fi, GPRS_NS2_ST_RECOVERING, 0, 0); } else { priv->N = 0; - osmo_fsm_inst_state_chg(fi, GPRS_NS2_ST_ALIVE, 0, 0); + osmo_fsm_inst_state_chg(fi, GPRS_NS2_ST_RECOVERING, 0, 0); } break; } @@ -606,7 +606,7 @@ break; case GPRS_NS2_EV_RX_ALIVE_ACK: /* for VCs without RESET/BLOCK/UNBLOCK, the connections comes after ALIVE_ACK unblocked */ - if (fi->state == GPRS_NS2_ST_ALIVE) + if (fi->state == GPRS_NS2_ST_RECOVERING) ns2_st_alive(fi, event, data); else recv_test_procedure(fi); @@ -630,7 +630,7 @@ 0, msg); break; /* ALIVE can receive UNITDATA if the ALIVE_ACK is lost */ - case GPRS_NS2_ST_ALIVE: + case GPRS_NS2_ST_RECOVERING: case GPRS_NS2_ST_UNBLOCKED: ns2_recv_unitdata(fi, msg); return; -- To view, visit https://gerrit.osmocom.org/c/libosmocore/+/22643 To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings Gerrit-Project: libosmocore Gerrit-Branch: master Gerrit-Change-Id: I0b29e8ce6444546d90bde68b1f957f1013238784 Gerrit-Change-Number: 22643 Gerrit-PatchSet: 3 Gerrit-Owner: lynxis lazus <lynxis at fe80.eu> Gerrit-Reviewer: Jenkins Builder Gerrit-Reviewer: laforge <laforge at osmocom.org> 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/20210203/18309b1f/attachment.htm>