From 00a2721e4c881f3b2b7c629a9e665071f99d4d00 Mon Sep 17 00:00:00 2001 From: Neels Hofmeyr Date: Mon, 8 Jul 2019 17:41:25 +0200 Subject: remove double BSSMAP Clear on HO failure If a handover fails when the new lchan is already fully established, osmo-bsc so far caused two BSSMAP Clear Requests to be sent out to the MSC: one caused by detaching the lchan from the gscon, one from returning the gscon back to ST_ACTIVE, which detects that no lchan is present and Clears. In fact only one of those is necessary. Checking for the presence of an lchan when entering ST_ACTIVE is an earlier attempt to catch insane situations. Since then, osmo-bsc has acquired other logic that will ensure sending a Clear Request in all cases, see gscon_forget_lchan(). Sending another BSSMAP Clear Request in ST_ACTIVE's onenter is simply not necessary. Drop gscon_fsm_active_onenter() entirely. Note: the double Clear Request is currently hit by TC_ho_out_fail_no_ho_detect(), which currently fails and will pass again after this patch; however, osmo-bsc should actually not release the lchan at all during this test, see OS#4093. In other words, osmo-bsc behavior for this scenario as well as TC_ho_out_fail_no_ho_detect() need to be changed, and the test will, once fixed, not be useful to trigger this issue anymore. Related: OS#4078 Change-Id: Iac1519eb8b24e8523caec682f9ac8e6dcf1327ce --- src/osmo-bsc/bsc_subscr_conn_fsm.c | 8 -------- 1 file changed, 8 deletions(-) (limited to 'src/osmo-bsc/bsc_subscr_conn_fsm.c') diff --git a/src/osmo-bsc/bsc_subscr_conn_fsm.c b/src/osmo-bsc/bsc_subscr_conn_fsm.c index bc5cb27fa..f8784f9ba 100644 --- a/src/osmo-bsc/bsc_subscr_conn_fsm.c +++ b/src/osmo-bsc/bsc_subscr_conn_fsm.c @@ -343,13 +343,6 @@ static void gscon_fsm_wait_cc(struct osmo_fsm_inst *fi, uint32_t event, void *da } } -static void gscon_fsm_active_onenter(struct osmo_fsm_inst *fi, uint32_t prev_state) -{ - struct gsm_subscriber_connection *conn = fi->priv; - if (!conn->lchan) - gscon_bssmap_clear(conn, GSM0808_CAUSE_EQUIPMENT_FAILURE); -} - /* We're on an active subscriber connection, passing DTAP back and forth */ static void gscon_fsm_active(struct osmo_fsm_inst *fi, uint32_t event, void *data) { @@ -605,7 +598,6 @@ static const struct osmo_fsm_state gscon_fsm_states[] = { S(GSCON_EV_HANDOVER_START), .out_state_mask = S(ST_CLEARING) | S(ST_ASSIGNMENT) | S(ST_HANDOVER), - .onenter = gscon_fsm_active_onenter, .action = gscon_fsm_active, }, [ST_ASSIGNMENT] = { -- cgit v1.2.3