mirror of
https://github.com/open5gs/open5gs.git
synced 2026-05-05 23:37:22 +00:00
Update TAU Accept & Initial Context Setup Failure
This commit is contained in:
parent
b040214364
commit
ca79c05fe6
5 changed files with 23 additions and 13 deletions
|
|
@ -370,6 +370,7 @@ status_t nas_send_deactivate_bearer_context_request(mme_bearer_t *bearer)
|
|||
|
||||
status_t nas_send_tau_accept(mme_ue_t *mme_ue)
|
||||
{
|
||||
#if OLD_TAU_ACCEPT
|
||||
status_t rv;
|
||||
enb_ue_t *enb_ue = NULL;
|
||||
pkbuf_t *s1apbuf = NULL, *emmbuf = NULL;
|
||||
|
|
@ -407,6 +408,18 @@ status_t nas_send_tau_accept(mme_ue_t *mme_ue)
|
|||
rv = nas_send_to_enb(mme_ue, s1apbuf);
|
||||
d_assert(rv == CORE_OK, return CORE_ERROR, "nas send error");
|
||||
}
|
||||
#else /* Change new code */
|
||||
status_t rv;
|
||||
pkbuf_t *emmbuf = NULL;
|
||||
|
||||
d_assert(mme_ue, return CORE_ERROR, "Null param");
|
||||
|
||||
rv = emm_build_tau_accept(&emmbuf, mme_ue);
|
||||
d_assert(rv == CORE_OK, return CORE_ERROR, "emm build error");
|
||||
|
||||
rv = nas_send_to_downlink_nas_transport(mme_ue, emmbuf);
|
||||
d_assert(rv == CORE_OK,, "nas_send_to_downlink_nas_transport");
|
||||
#endif
|
||||
|
||||
return CORE_OK;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -387,6 +387,8 @@ void s1ap_handle_initial_context_setup_failure(
|
|||
* that no hanging resources remain at the eNB.
|
||||
*/
|
||||
|
||||
#if 0 /* NOTHING TO DO */
|
||||
|
||||
#if 0 /* FIXME : Does it needed? */
|
||||
rv = nas_send_service_reject(mme_ue,
|
||||
EMM_CAUSE_PROTOCOL_ERROR_UNSPECIFIED);
|
||||
|
|
@ -416,6 +418,8 @@ void s1ap_handle_initial_context_setup_failure(
|
|||
rv = mme_ue_deassociate(mme_ue);
|
||||
d_assert(rv == CORE_OK,, "mme_ue_deassociate() failed");
|
||||
|
||||
#endif
|
||||
|
||||
#endif
|
||||
}
|
||||
else
|
||||
|
|
|
|||
|
|
@ -931,6 +931,8 @@ pgw_sess_t *pgw_sess_add(
|
|||
index_alloc(&pgw_sess_pool, &sess);
|
||||
d_assert(sess, return NULL, "Null param");
|
||||
|
||||
sess->gnode = NULL;
|
||||
|
||||
sess->pgw_s5c_teid = sess->index; /* derived from an index */
|
||||
|
||||
/* Set IMSI */
|
||||
|
|
@ -1171,6 +1173,8 @@ pgw_bearer_t* pgw_bearer_add(pgw_sess_t *sess)
|
|||
bearer->pgw_s5u_teid = bearer->index;
|
||||
|
||||
bearer->sess = sess;
|
||||
bearer->gnode = NULL;
|
||||
|
||||
list_append(&sess->bearer_list, bearer);
|
||||
|
||||
return bearer;
|
||||
|
|
|
|||
|
|
@ -670,6 +670,7 @@ sgw_sess_t *sgw_sess_add(
|
|||
core_cpystrn(sess->pdn.apn, apn, MAX_APN_LEN+1);
|
||||
|
||||
sess->sgw_ue = sgw_ue;
|
||||
sess->gnode = NULL;
|
||||
|
||||
list_init(&sess->bearer_list);
|
||||
|
||||
|
|
@ -908,6 +909,7 @@ sgw_tunnel_t* sgw_tunnel_add(sgw_bearer_t *bearer, c_uint8_t interface_type)
|
|||
tunnel->local_teid = tunnel->index;
|
||||
|
||||
tunnel->bearer = bearer;
|
||||
tunnel->gnode = NULL;
|
||||
|
||||
list_append(&bearer->tunnel_list, tunnel);
|
||||
|
||||
|
|
|
|||
|
|
@ -1085,19 +1085,6 @@ static void attach_test3(abts_case *tc, void *data)
|
|||
ABTS_INT_EQUAL(tc, CORE_OK, rv);
|
||||
pkbuf_free(recvbuf);
|
||||
|
||||
/* Receive UE Context Release Command */
|
||||
recvbuf = pkbuf_alloc(0, MAX_SDU_LEN);
|
||||
rv = tests1ap_enb_read(sock, recvbuf);
|
||||
ABTS_INT_EQUAL(tc, CORE_OK, rv);
|
||||
pkbuf_free(recvbuf);
|
||||
|
||||
/* Send UE Release Complete */
|
||||
rv = tests1ap_build_ue_context_release_complete(&sendbuf, msgindex+1);
|
||||
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));
|
||||
out:
|
||||
doc = BCON_NEW("imsi", BCON_UTF8("001010123456797"));
|
||||
ABTS_PTR_NOTNULL(tc, doc);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue