mme_ue_remove() if detach request is switch-off
This commit is contained in:
parent
131fb3ac79
commit
d8f23bed1a
|
@ -184,13 +184,14 @@ status_t nas_send_detach_accept(mme_ue_t *mme_ue)
|
|||
enb_ue_t *enb_ue = NULL;
|
||||
pkbuf_t *emmbuf = NULL;
|
||||
S1ap_Cause_t cause;
|
||||
c_uint8_t ue_ctx_rel_action = S1AP_UE_CTX_REL_NO_ACTION;
|
||||
|
||||
d_assert(mme_ue, return CORE_ERROR, "Null param");
|
||||
enb_ue = mme_ue->enb_ue;
|
||||
d_assert(enb_ue, return CORE_ERROR, "Null param");
|
||||
|
||||
/* reply with detach accept */
|
||||
if ((mme_ue->detach_type.switch_off & 0x1) == 0)
|
||||
if (mme_ue->detach_type.switch_off == 0)
|
||||
{
|
||||
rv = emm_build_detach_accept(&emmbuf, mme_ue);
|
||||
d_assert(rv == CORE_OK && emmbuf, return CORE_ERROR,
|
||||
|
@ -199,12 +200,16 @@ status_t nas_send_detach_accept(mme_ue_t *mme_ue)
|
|||
rv = nas_send_to_downlink_nas_transport(mme_ue, emmbuf);
|
||||
d_assert(rv == CORE_OK, return CORE_ERROR, "nas send failed");
|
||||
}
|
||||
else
|
||||
{
|
||||
ue_ctx_rel_action = S1AP_UE_CTX_REL_REMOVE_MME_UE_CONTEXT;
|
||||
}
|
||||
|
||||
/* FIXME : delay is needed */
|
||||
cause.present = S1ap_Cause_PR_nas;
|
||||
cause.choice.nas = S1ap_CauseNas_detach;
|
||||
rv = s1ap_send_ue_context_release_commmand(
|
||||
enb_ue, &cause, S1AP_UE_CTX_REL_NO_ACTION, 0);
|
||||
enb_ue, &cause, ue_ctx_rel_action, 0);
|
||||
d_assert(rv == CORE_OK, return CORE_ERROR, "s1ap send error");
|
||||
|
||||
return CORE_OK;
|
||||
|
|
|
@ -165,6 +165,13 @@ static status_t bearer_binding(pgw_sess_t *sess, gx_message_t *gx_message)
|
|||
/* Update Bearer Request will encode updated QoS parameter */
|
||||
qos_presence = 1;
|
||||
}
|
||||
|
||||
if (tft_presence == 0 && qos_presence == 0)
|
||||
{
|
||||
d_warn("[IGNORE] Update Bearer Request : "
|
||||
"Both QoS and TFT is NULL");
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
for (j = 0; j < pcc_rule->num_of_flow; j++)
|
||||
|
|
|
@ -1012,7 +1012,9 @@ status_t tests1ap_build_pdn_disconnectivity_request(
|
|||
"000d40380000"
|
||||
"0500000005c08000 0108000800030001 00001a000b0a2732 423c53040206d206"
|
||||
"006440080055f501 0019d01000434006 0055f5011022",
|
||||
"",
|
||||
"000d40380000"
|
||||
"0500000005c08000 0108000800030001 00001a000b0a271a 776620040206d206"
|
||||
"006440080055f501 0019d01000434006 0055f5011022",
|
||||
"",
|
||||
|
||||
"",
|
||||
|
@ -1026,7 +1028,7 @@ status_t tests1ap_build_pdn_disconnectivity_request(
|
|||
};
|
||||
c_uint16_t len[TESTS1AP_MAX_MESSAGE] = {
|
||||
60,
|
||||
0,
|
||||
60,
|
||||
0,
|
||||
|
||||
0,
|
||||
|
@ -1350,7 +1352,9 @@ status_t tests1ap_build_deactivate_bearer_accept(
|
|||
"000d40370000"
|
||||
"0500000005c00000 0001000800030001 00001a000a0927a9 a1b2bd057200ce00"
|
||||
"6440080055f50100 19d0100043400600 55f5011022",
|
||||
"",
|
||||
"000d40370000"
|
||||
"0500000005c00000 0001000800030001 00001a000a09275a af43d9056200ce00"
|
||||
"6440080055f50100 19d0100043400600 55f5011022",
|
||||
|
||||
"",
|
||||
"",
|
||||
|
@ -1364,7 +1368,7 @@ status_t tests1ap_build_deactivate_bearer_accept(
|
|||
c_uint16_t len[TESTS1AP_MAX_MESSAGE] = {
|
||||
59,
|
||||
59,
|
||||
0,
|
||||
59,
|
||||
|
||||
0,
|
||||
0,
|
||||
|
|
|
@ -306,7 +306,7 @@ static void volte_test1(abts_case *tc, void *data)
|
|||
|
||||
core_sleep(time_from_msec(300));
|
||||
|
||||
/* Deactivate EPS bearer context accept */
|
||||
/* Send Deactivate EPS bearer context accept */
|
||||
rv = tests1ap_build_deactivate_bearer_accept(&sendbuf, msgindex+1);
|
||||
ABTS_INT_EQUAL(tc, CORE_OK, rv);
|
||||
rv = tests1ap_enb_send(sock, sendbuf);
|
||||
|
@ -314,9 +314,8 @@ static void volte_test1(abts_case *tc, void *data)
|
|||
|
||||
core_sleep(time_from_msec(300));
|
||||
|
||||
#if 0
|
||||
/* Send PDN disconnectivity request */
|
||||
rv = tests1ap_build_pdn_disconnectivity_request(&sendbuf, msgindex);
|
||||
rv = tests1ap_build_pdn_disconnectivity_request(&sendbuf, msgindex+1);
|
||||
ABTS_INT_EQUAL(tc, CORE_OK, rv);
|
||||
rv = tests1ap_enb_send(sock, sendbuf);
|
||||
ABTS_INT_EQUAL(tc, CORE_OK, rv);
|
||||
|
@ -334,14 +333,17 @@ static void volte_test1(abts_case *tc, void *data)
|
|||
rv = tests1ap_enb_send(sock, sendbuf);
|
||||
ABTS_INT_EQUAL(tc, CORE_OK, rv);
|
||||
|
||||
/* Deactivate EPS bearer context accept */
|
||||
rv = tests1ap_build_deactivate_bearer_accept(&sendbuf, msgindex);
|
||||
core_sleep(time_from_msec(300));
|
||||
|
||||
/* Send Deactivate EPS bearer context accept */
|
||||
rv = tests1ap_build_deactivate_bearer_accept(&sendbuf, msgindex+2);
|
||||
ABTS_INT_EQUAL(tc, CORE_OK, rv);
|
||||
rv = tests1ap_enb_send(sock, sendbuf);
|
||||
ABTS_INT_EQUAL(tc, CORE_OK, rv);
|
||||
|
||||
core_sleep(time_from_msec(300));
|
||||
|
||||
#if 0
|
||||
/* Send INVALID PDN Connectivity Request */
|
||||
rv = tests1ap_build_pdn_connectivity_request(&sendbuf, msgindex+1);
|
||||
ABTS_INT_EQUAL(tc, CORE_OK, rv);
|
||||
|
|
Loading…
Reference in New Issue