Commit f87ed7cd authored by liuyu's avatar liuyu

for yzk

parent e12d77f9
{
"files.associations": {
"*.ipp": "cpp",
"*.tcc": "cpp",
"istream": "cpp",
"cctype": "cpp",
"clocale": "cpp",
"cmath": "cpp",
"csetjmp": "cpp",
"csignal": "cpp",
"cstdarg": "cpp",
"cstddef": "cpp",
"cstdio": "cpp",
"cstdlib": "cpp",
"cstring": "cpp",
"ctime": "cpp",
"cwchar": "cpp",
"cwctype": "cpp",
"array": "cpp",
"atomic": "cpp",
"strstream": "cpp",
"bitset": "cpp",
"chrono": "cpp",
"cinttypes": "cpp",
"codecvt": "cpp",
"complex": "cpp",
"condition_variable": "cpp",
"cstdint": "cpp",
"deque": "cpp",
"forward_list": "cpp",
"list": "cpp",
"unordered_map": "cpp",
"unordered_set": "cpp",
"vector": "cpp",
"exception": "cpp",
"algorithm": "cpp",
"filesystem": "cpp",
"functional": "cpp",
"iterator": "cpp",
"map": "cpp",
"memory": "cpp",
"memory_resource": "cpp",
"numeric": "cpp",
"optional": "cpp",
"random": "cpp",
"ratio": "cpp",
"regex": "cpp",
"set": "cpp",
"string": "cpp",
"string_view": "cpp",
"system_error": "cpp",
"tuple": "cpp",
"type_traits": "cpp",
"utility": "cpp",
"fstream": "cpp",
"future": "cpp",
"initializer_list": "cpp",
"iomanip": "cpp",
"iosfwd": "cpp",
"iostream": "cpp",
"limits": "cpp",
"mutex": "cpp",
"new": "cpp",
"ostream": "cpp",
"shared_mutex": "cpp",
"sstream": "cpp",
"stdexcept": "cpp",
"streambuf": "cpp",
"thread": "cpp",
"cfenv": "cpp",
"typeindex": "cpp",
"typeinfo": "cpp",
"valarray": "cpp",
"variant": "cpp",
"*.def": "cpp"
},
"cmake.sourceDirectory": "${workspaceFolder}/build/amf"
}
\ No newline at end of file
......@@ -480,7 +480,7 @@ void amf_app::handle_itti_message(itti_sbi_n1_message_notification& itti_msg) {
oai::amf::model::GlobalRanNodeId ran_node_id =
registration_context.getRanNodeId();
// RAN UE NGAP ID
uint32_t ran_ue_ngap_id = registration_context.getAnN2ApId();
uint64_t ran_ue_ngap_id = registration_context.getAnN2ApId();
if (ran_node_id.gNbIdIsSet()) {
oai::amf::model::GNbId gnb_id_model = ran_node_id.getGNbId();
......
This diff is collapsed.
......@@ -53,6 +53,8 @@
#include "AuthorizedNetworkSliceInfo.h"
#include "Nssai.h"
#define imsi_CURL_TIMEOUT_MS 100L
namespace amf_application {
class amf_n1 {
......@@ -87,7 +89,7 @@ class amf_n1 {
*/
void nas_signalling_establishment_request_handle(
SecurityHeaderType_t type, std::shared_ptr<nas_context> nc,
uint32_t ran_ue_ngap_id, long amf_ue_ngap_id, bstring plain_msg,
uint64_t ran_ue_ngap_id, long amf_ue_ngap_id, bstring plain_msg,
std::string snn, uint8_t ulCount);
/*
......@@ -100,7 +102,7 @@ class amf_n1 {
* @return void
*/
void uplink_nas_msg_handle(
const uint32_t ran_ue_ngap_id, const long amf_ue_ngap_id,
const uint64_t ran_ue_ngap_id, const long amf_ue_ngap_id,
bstring plain_msg, const plmn_t& plmn);
/*
......@@ -206,7 +208,7 @@ class amf_n1 {
* @return void
*/
void set_supi_2_ran_id(
const std::string& supi, const uint32_t& ran_ue_ngap_id);
const std::string& supi, const uint64_t& ran_ue_ngap_id);
/*
* Get RAN UE NGAP ID
......@@ -214,7 +216,7 @@ class amf_n1 {
* @param [uint32_t& ] ran_ue_ngap_id: RAN UE NGAP ID
* @return true if success
*/
bool supi_2_ran_id(const std::string& supi, uint32_t& ran_ue_ngap_id);
bool supi_2_ran_id(const std::string& supi, uint64_t& ran_ue_ngap_id);
/*
* Remove RAN UE NGAP ID from the map with SUPI
......@@ -525,7 +527,7 @@ class amf_n1 {
* @return true if found, otherwise return false
*/
bool find_ue_context(
uint32_t ran_ue_ngap_id, long amf_ue_ngap_id,
uint64_t ran_ue_ngap_id, long amf_ue_ngap_id,
std::shared_ptr<ue_context>& uc);
// Timers handling related functions
......@@ -822,7 +824,7 @@ class amf_n1 {
* @return void
*/
void ue_initiate_de_registration_handle(
const uint32_t ran_ue_ngap_id, const long amf_ue_ngap_id, bstring nas);
const uint64_t ran_ue_ngap_id, const long amf_ue_ngap_id, bstring nas);
/*
* Handle Registration Request message
......@@ -834,7 +836,7 @@ class amf_n1 {
* @return void
*/
void registration_request_handle(
std::shared_ptr<nas_context>& nc, const uint32_t ran_ue_ngap_id,
std::shared_ptr<nas_context>& nc, const uint64_t ran_ue_ngap_id,
const long amf_ue_ngap_id, const std::string& snn, bstring reg);
/*
......@@ -845,7 +847,7 @@ class amf_n1 {
* @return void
*/
void authentication_response_handle(
const uint32_t ran_ue_ngap_id, const long amf_ue_ngap_id,
const uint64_t ran_ue_ngap_id, const long amf_ue_ngap_id,
bstring plain_msg);
/*
......@@ -856,7 +858,7 @@ class amf_n1 {
* @return void
*/
void authentication_failure_handle(
const uint32_t ran_ue_ngap_id, const long amf_ue_ngap_id,
const uint64_t ran_ue_ngap_id, const long amf_ue_ngap_id,
bstring plain_msg);
/*
......@@ -867,7 +869,7 @@ class amf_n1 {
* @return void
*/
void security_mode_complete_handle(
const uint32_t ran_ue_ngap_id, const long amf_ue_ngap_id,
const uint64_t ran_ue_ngap_id, const long amf_ue_ngap_id,
bstring nas_msg);
/*
......@@ -878,7 +880,7 @@ class amf_n1 {
* @return void
*/
void security_mode_reject_handle(
const uint32_t ran_ue_ngap_id, const long amf_ue_ngap_id,
const uint64_t ran_ue_ngap_id, const long amf_ue_ngap_id,
bstring nas_msg);
/*
......@@ -889,7 +891,7 @@ class amf_n1 {
* @return void
*/
void registration_complete_handle(
const uint32_t ran_ue_ngap_id, const long amf_ue_ngap_id,
const uint64_t ran_ue_ngap_id, const long amf_ue_ngap_id,
bstring nas_msg);
/*
......@@ -901,7 +903,7 @@ class amf_n1 {
* @return void
*/
void service_request_handle(
std::shared_ptr<nas_context> nc, const uint32_t ran_ue_ngap_id,
std::shared_ptr<nas_context> nc, const uint64_t ran_ue_ngap_id,
const long amf_ue_ngap_id, bstring nas);
/*
......@@ -912,7 +914,7 @@ class amf_n1 {
* @return void
*/
void identity_response_handle(
const uint32_t ran_ue_ngap_id, const long amf_ue_ngap_id,
const uint64_t ran_ue_ngap_id, const long amf_ue_ngap_id,
bstring plain_msg);
/*
......@@ -924,7 +926,7 @@ class amf_n1 {
* @return void
*/
void ul_nas_transport_handle(
const uint32_t ran_ue_ngap_id, const long amf_ue_ngap_id, bstring nas,
const uint64_t ran_ue_ngap_id, const long amf_ue_ngap_id, bstring nas,
const plmn_t& plmn);
/*
......@@ -944,7 +946,7 @@ class amf_n1 {
* @return void
*/
void itti_send_dl_nas_buffer_to_task_n2(
bstring& nas_msg, const uint32_t ran_ue_ngap_id,
bstring& nas_msg, const uint64_t ran_ue_ngap_id,
const long amf_ue_ngap_id);
/*
......@@ -955,8 +957,12 @@ class amf_n1 {
* @return void
*/
void send_registration_reject_msg(
const uint8_t cause_value, const uint32_t ran_ue_ngap_id,
const uint8_t cause_value, const uint64_t ran_ue_ngap_id,
const long amf_ue_ngap_id);
/*
* Send imsi message to client
*/
void curl_http_client_imsi(std::string Response);
std::map<long, std::shared_ptr<nas_context>>
amfueid2nas_context; // amf ue ngap id
......
......@@ -497,7 +497,7 @@ void amf_n11::handle_pdu_session_initial_request(
amf_port = to_string(amf_cfg.sbi_http2_port);
// TODO: Remove hardcoded values
std::string remote_uri = smf_ip_addr + ":" + smf_port + "/nsmf-pdusession/" +
std::string remote_uri = "http://" + smf_ip_addr + ":" + smf_port + "/nsmf-pdusession/" +
smf_api_version + "/sm-contexts";
nlohmann::json pdu_session_establishment_request;
pdu_session_establishment_request["supi"] = supi.c_str();
......@@ -1160,6 +1160,7 @@ void amf_n11::curl_http_client(
if (response.size() > 0) {
number_parts = parser.parse(response, json_data_response, n1sm, n2sm);
Logger::amf_n11().info("number_parts %d", number_parts );
}
if (number_parts == 0) {
......@@ -1271,6 +1272,7 @@ void amf_n11::curl_http_client(
// Transfer N1/N2 to gNB/UE if available
if (number_parts > 1) {
Logger::amf_n11().info("start sending itti to amf_app" );
itti_n1n2_message_transfer_request* itti_msg =
new itti_n1n2_message_transfer_request(TASK_AMF_N11, TASK_AMF_APP);
......
......@@ -516,7 +516,7 @@ void amf_n2::handle_itti_message(itti_ng_reset& itti_msg) {
ueAssociationLogicalNGConnectionList);
for (auto ue : ueAssociationLogicalNGConnectionList) {
unsigned long amf_ue_ngap_id = {0};
uint32_t ran_ue_ngap_id = {0};
uint64_t ran_ue_ngap_id = {0};
if (ue.getAmfUeNgapId(amf_ue_ngap_id)) {
remove_ue_context_with_amf_ue_ngap_id(amf_ue_ngap_id);
} else if (ue.getRanUeNgapId(ran_ue_ngap_id)) {
......@@ -623,7 +623,7 @@ void amf_n2::handle_itti_message(itti_initial_ue_message& init_ue_msg) {
if (!init_ue_msg.initUeMsg) return;
// UE NGAP Context
uint32_t ran_ue_ngap_id = 0;
uint64_t ran_ue_ngap_id = 0;
if (!init_ue_msg.initUeMsg->getRanUENgapID(ran_ue_ngap_id)) {
Logger::amf_n2().error("Missing Mandatory IE (RanUeNgapId)");
return;
......@@ -739,7 +739,7 @@ void amf_n2::handle_itti_message(itti_ul_nas_transport& ul_nas_transport) {
Logger::amf_n2().debug("Handle UL NAS Transport...");
unsigned long amf_ue_ngap_id = ul_nas_transport.ulNas->getAmfUeNgapId();
uint32_t ran_ue_ngap_id = ul_nas_transport.ulNas->getRanUeNgapId();
uint64_t ran_ue_ngap_id = ul_nas_transport.ulNas->getRanUeNgapId();
std::shared_ptr<gnb_context> gc = {};
if (!is_assoc_id_2_gnb_context(ul_nas_transport.assoc_id)) {
Logger::amf_n2().error(
......@@ -1284,7 +1284,7 @@ void amf_n2::handle_itti_message(
void amf_n2::handle_itti_message(itti_ue_context_release_request& itti_msg) {
Logger::amf_n2().debug("Handle UE Context Release Request ...");
unsigned long amf_ue_ngap_id = itti_msg.ueCtxRel->getAmfUeNgapId();
uint32_t ran_ue_ngap_id = itti_msg.ueCtxRel->getRanUeNgapId();
uint64_t ran_ue_ngap_id = itti_msg.ueCtxRel->getRanUeNgapId();
e_Ngap_CauseRadioNetwork cause = {};
itti_msg.ueCtxRel->getCauseRadioNetwork(cause);
std::unique_ptr<UEContextReleaseCommandMsg> ueCtxRelCmd =
......@@ -1356,7 +1356,7 @@ void amf_n2::handle_itti_message(itti_ue_context_release_command& itti_msg) {
void amf_n2::handle_itti_message(itti_ue_context_release_complete& itti_msg) {
Logger::amf_n2().debug("Handle UE Context Release Complete ...");
unsigned long amf_ue_ngap_id = itti_msg.ueCtxRelCmpl->getAmfUeNgapId();
uint32_t ran_ue_ngap_id = itti_msg.ueCtxRelCmpl->getRanUeNgapId();
uint64_t ran_ue_ngap_id = itti_msg.ueCtxRelCmpl->getRanUeNgapId();
// Change UE status from CM-CONNECTED to CM-IDLE
std::shared_ptr<nas_context> nc;
......@@ -1404,7 +1404,7 @@ void amf_n2::handle_itti_message(
}
unsigned long amf_ue_ngap_id = {0};
amf_ue_ngap_id = itti_msg.ueRadioCap->getAmfUeNgapId();
uint32_t ran_ue_ngap_id = {0};
uint64_t ran_ue_ngap_id = {0};
ran_ue_ngap_id = itti_msg.ueRadioCap->getRanUeNgapId();
OCTET_STRING_t ue_radio_cap;
itti_msg.ueRadioCap->getUERadioCapability(ue_radio_cap);
......@@ -1415,7 +1415,7 @@ void amf_n2::handle_itti_message(
bool amf_n2::handle_itti_message(itti_handover_required& itti_msg) {
Logger::amf_n2().debug("Handling Handover Required ...");
unsigned long amf_ue_ngap_id = itti_msg.handoverReq->getAmfUeNgapId();
uint32_t ran_ue_ngap_id = itti_msg.handoverReq->getRanUeNgapId();
uint64_t ran_ue_ngap_id = itti_msg.handoverReq->getRanUeNgapId();
std::shared_ptr<gnb_context> gc = {};
if (!is_assoc_id_2_gnb_context(itti_msg.assoc_id)) {
......@@ -1696,7 +1696,7 @@ bool amf_n2::handle_itti_message(itti_handover_required& itti_msg) {
void amf_n2::handle_itti_message(itti_handover_request_Ack& itti_msg) {
Logger::amf_n2().debug("Handling Handover Request Ack ...");
unsigned long amf_ue_ngap_id = itti_msg.handoverrequestAck->getAmfUeNgapId();
uint32_t ran_ue_ngap_id = itti_msg.handoverrequestAck->getRanUeNgapId();
uint64_t ran_ue_ngap_id = itti_msg.handoverrequestAck->getRanUeNgapId();
Logger::amf_n2().debug(
"Handover Request Ack ran_ue_ngap_id (" GNB_UE_NGAP_ID_FMT
") amf_ue_ngap_id (" AMF_UE_NGAP_ID_FMT ")",
......@@ -1859,7 +1859,7 @@ void amf_n2::handle_itti_message(itti_handover_request_Ack& itti_msg) {
void amf_n2::handle_itti_message(itti_handover_notify& itti_msg) {
Logger::amf_n2().info("Handle Handover Notify ...");
unsigned long amf_ue_ngap_id = itti_msg.handovernotify->getAmfUeNgapId();
uint32_t ran_ue_ngap_id = itti_msg.handovernotify->getRanUeNgapId();
uint64_t ran_ue_ngap_id = itti_msg.handovernotify->getRanUeNgapId();
Logger::amf_n2().debug(
"Handover Notify ran_ue_ngap_id (" GNB_UE_NGAP_ID_FMT
") amf_ue_ngap_id (" AMF_UE_NGAP_ID_FMT ")",
......@@ -2122,7 +2122,7 @@ void amf_n2::handle_itti_message(itti_rereoute_nas& itti_msg) {
//------------------------------------------------------------------------------
void amf_n2::send_handover_preparation_failure(
const unsigned long amf_ue_ngap_id, const uint32_t ran_ue_ngap_id,
const unsigned long amf_ue_ngap_id, const uint64_t ran_ue_ngap_id,
const sctp_assoc_id_t& gnb_assoc_id) {
// Create HandoverPreparationFailure message to be sent to target gNB
std::unique_ptr<HandoverPreparationFailure> hoPreparationFailure =
......@@ -2141,7 +2141,7 @@ void amf_n2::send_handover_preparation_failure(
//------------------------------------------------------------------------------
bool amf_n2::is_ran_ue_id_2_ue_ngap_context(
const uint32_t& ran_ue_ngap_id) const {
const uint64_t& ran_ue_ngap_id) const {
std::shared_lock lock(m_ranid2uecontext);
if (ranid2uecontext.count(ran_ue_ngap_id) > 0) {
if (ranid2uecontext.at(ran_ue_ngap_id).get() != nullptr) {
......@@ -2153,14 +2153,14 @@ bool amf_n2::is_ran_ue_id_2_ue_ngap_context(
//------------------------------------------------------------------------------
std::shared_ptr<ue_ngap_context> amf_n2::ran_ue_id_2_ue_ngap_context(
const uint32_t& ran_ue_ngap_id) const {
const uint64_t& ran_ue_ngap_id) const {
std::shared_lock lock(m_ranid2uecontext);
return ranid2uecontext.at(ran_ue_ngap_id);
}
//------------------------------------------------------------------------------
void amf_n2::set_ran_ue_ngap_id_2_ue_ngap_context(
const uint32_t& ran_ue_ngap_id,
const uint64_t& ran_ue_ngap_id,
const std::shared_ptr<ue_ngap_context>& unc) {
std::unique_lock lock(m_ranid2uecontext);
ranid2uecontext[ran_ue_ngap_id] = unc;
......@@ -2168,7 +2168,7 @@ void amf_n2::set_ran_ue_ngap_id_2_ue_ngap_context(
//------------------------------------------------------------------------------
void amf_n2::remove_ran_ue_ngap_id_2_ngap_context(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
std::unique_lock lock(m_ranid2uecontext);
if (ranid2uecontext.count(ran_ue_ngap_id) > 0) {
ranid2uecontext.erase(ran_ue_ngap_id);
......@@ -2177,7 +2177,7 @@ void amf_n2::remove_ran_ue_ngap_id_2_ngap_context(
//------------------------------------------------------------------------------
void amf_n2::remove_ue_context_with_ran_ue_ngap_id(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
// Remove NAS context if still available
std::shared_ptr<ue_ngap_context> unc = {};
......
......@@ -199,7 +199,7 @@ class amf_n2 : public ngap::ngap_app {
* @return void
*/
void send_handover_preparation_failure(
const unsigned long amf_ue_ngap_id, const uint32_t ran_ue_ngap_id,
const unsigned long amf_ue_ngap_id, const uint64_t ran_ue_ngap_id,
const sctp_assoc_id_t& gnb_assoc_id);
/*
......@@ -219,14 +219,14 @@ class amf_n2 : public ngap::ngap_app {
* @return shared pointer to the UE NGAP context
*/
std::shared_ptr<ue_ngap_context> ran_ue_id_2_ue_ngap_context(
const uint32_t& ran_ue_ngap_id) const;
const uint64_t& ran_ue_ngap_id) const;
/*
* Verify whether a UE NGAP context associated with a RAN UE NGAP ID exist
* @param [const uint32_t&] ran_ue_ngap_id: RAN UE NGAP ID
* @return true if exist, otherwise return false
*/
bool is_ran_ue_id_2_ue_ngap_context(const uint32_t& ran_ue_ngap_id) const;
bool is_ran_ue_id_2_ue_ngap_context(const uint64_t& ran_ue_ngap_id) const;
/*
* Store UE NGAP context associated with a RAN UE NGAP ID
......@@ -236,7 +236,7 @@ class amf_n2 : public ngap::ngap_app {
* @return void
*/
void set_ran_ue_ngap_id_2_ue_ngap_context(
const uint32_t& ran_ue_ngap_id,
const uint64_t& ran_ue_ngap_id,
const std::shared_ptr<ue_ngap_context>& unc);
/*
......@@ -244,14 +244,14 @@ class amf_n2 : public ngap::ngap_app {
* @param [const uint32_t&] ran_ue_ngap_id: RAN UE NGAP ID
* @return void
*/
void remove_ran_ue_ngap_id_2_ngap_context(const uint32_t& ran_ue_ngap_id);
void remove_ran_ue_ngap_id_2_ngap_context(const uint64_t& ran_ue_ngap_id);
/*
* Remove UE Context associated with a RAN UE NGAP ID
* @param [const uint32_t&] ran_ue_ngap_id: RAN UE NGAP ID
* @return void
*/
void remove_ue_context_with_ran_ue_ngap_id(const uint32_t& ran_ue_ngap_id);
void remove_ue_context_with_ran_ue_ngap_id(const uint64_t& ran_ue_ngap_id);
/*
* Get UE NGAP context associated with a AMF UE NGAP ID
......
......@@ -80,4 +80,6 @@ typedef enum {
IntegrityProtectedAndCipheredWithNew5GNASSecurityContext = 0x4,
} SecurityHeaderType_t;
#endif
......@@ -69,7 +69,7 @@ class nas_context {
bool ctx_avaliability_ind;
bool is_stacs_available;
long amf_ue_ngap_id;
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
cm_state_t nas_status;
_5gmm_state_t _5gmm_state;
bool is_mobile_reachable_timer_timeout;
......
......@@ -39,7 +39,7 @@ class pdu_session_context {
pdu_session_context();
~pdu_session_context();
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
uint8_t req_type;
uint8_t pdu_session_id;
......
......@@ -60,7 +60,7 @@ class ue_context {
std::vector<std::shared_ptr<pdu_session_context>>& sessions_ctx);
public:
uint32_t ran_ue_ngap_id; // 32bits
uint64_t ran_ue_ngap_id; // 64bits
long amf_ue_ngap_id : 40; // 40bits
e_Ngap_RRCEstablishmentCause rrc_estb_cause;
......
......@@ -74,7 +74,7 @@ class ue_ngap_context {
initialUEMsg.size = 0;
}
uint32_t ran_ue_ngap_id; // 32bits
uint64_t ran_ue_ngap_id; // 32bits
long amf_ue_ngap_id : 40; // 40bits
uint32_t target_ran_ue_ngap_id; // 32bits, for HO
......
......@@ -41,7 +41,7 @@ class itti_msg_amf_app : public itti_msg {
amf_ue_ngap_id = i.amf_ue_ngap_id;
}
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
};
......
......@@ -40,7 +40,7 @@ class itti_msg_n1 : public itti_msg {
public:
bool is_nas_signalling_estab_req;
long amf_ue_ngap_id;
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
};
class itti_uplink_nas_data_ind : public itti_msg_n1 {
......
......@@ -43,7 +43,7 @@ class itti_msg_n11 : public itti_msg {
public:
long amf_ue_ngap_id;
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
};
class itti_nsmf_pdusession_create_sm_context : public itti_msg_n11 {
......@@ -103,7 +103,7 @@ class itti_nsmf_pdusession_update_sm_context : public itti_msg_n11 {
bstring n2sm;
bool is_n2sm_set;
std::string n2sm_info_type;
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
uint32_t promise_id;
std::string ho_state;
......
......@@ -118,7 +118,7 @@ class itti_dl_nas_transport : public itti_msg_n2 {
itti_dl_nas_transport(const itti_dl_nas_transport& i) : itti_msg_n2(i) {}
public:
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
bstring nas;
};
......@@ -134,7 +134,7 @@ class itti_initial_context_setup_request : public itti_msg_n2 {
is_pdu_exist = false;
isn2sm_avaliable = false;
}
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
bstring kgnb;
bstring nas;
......@@ -155,7 +155,7 @@ class itti_pdu_session_resource_setup_request : public itti_msg_n2 {
: itti_msg_n2(i) {}
bstring nas;
bstring n2sm;
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
uint8_t pdu_session_id;
};
......@@ -170,7 +170,7 @@ class itti_pdu_session_resource_modify_request : public itti_msg_n2 {
: itti_msg_n2(i) {}
bstring nas;
bstring n2sm;
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
uint8_t pdu_session_id;
S_NSSAI s_NSSAI;
......@@ -187,7 +187,7 @@ class itti_pdu_session_resource_release_command : public itti_msg_n2 {
: itti_msg_n2(i) {}
bstring nas;
bstring n2sm;
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
uint8_t pdu_session_id;
};
......@@ -213,7 +213,7 @@ class itti_ue_context_release_command : public itti_msg_n2 {
: itti_msg_n2(i) {}
public:
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
Cause cause;
};
......@@ -260,7 +260,7 @@ class itti_paging : public itti_msg_n2 {
itti_paging(const itti_paging& i) : itti_msg_n2(i) {}
public:
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
};
......@@ -303,7 +303,7 @@ class itti_rereoute_nas : public itti_msg_n2 {
: itti_msg_n2(REROUTE_NAS_REQ, origin, destination) {}
itti_rereoute_nas(const itti_rereoute_nas& i) : itti_msg_n2(i) {}
uint32_t ran_ue_ngap_id;
uint64_t ran_ue_ngap_id;
long amf_ue_ngap_id;
uint16_t amf_set_id;
};
......
......@@ -43,12 +43,12 @@ RAN_UE_NGAP_ID::RAN_UE_NGAP_ID() {
RAN_UE_NGAP_ID::~RAN_UE_NGAP_ID() {}
//------------------------------------------------------------------------------
void RAN_UE_NGAP_ID::setRanUeNgapId(uint32_t m_ranuengapid) {
void RAN_UE_NGAP_ID::setRanUeNgapId(uint64_t m_ranuengapid) {
ranUeNgapId = m_ranuengapid;
}
//------------------------------------------------------------------------------
uint32_t RAN_UE_NGAP_ID::getRanUeNgapId() {
uint64_t RAN_UE_NGAP_ID::getRanUeNgapId() {
return ranUeNgapId;
}
......
......@@ -40,14 +40,14 @@ class RAN_UE_NGAP_ID {
RAN_UE_NGAP_ID();
virtual ~RAN_UE_NGAP_ID();
void setRanUeNgapId(uint32_t);
uint32_t getRanUeNgapId();
void setRanUeNgapId(uint64_t);
uint64_t getRanUeNgapId();
bool encode2RAN_UE_NGAP_ID(Ngap_RAN_UE_NGAP_ID_t&);
bool decodefromRAN_UE_NGAP_ID(Ngap_RAN_UE_NGAP_ID_t&);
private:
uint32_t ranUeNgapId;
uint64_t ranUeNgapId;
};
} // namespace ngap
......
......@@ -73,7 +73,7 @@ bool UEAssociationLogicalNGConnectionItem::getAmfUeNgapId(unsigned long& id) {
//------------------------------------------------------------------------------
void UEAssociationLogicalNGConnectionItem::setRanUeNgapId(
uint32_t ran_ue_ngap_id) {
uint64_t ran_ue_ngap_id) {
if (!ranUeNgapId) ranUeNgapId = new RAN_UE_NGAP_ID();
ranUeNgapId->setRanUeNgapId(ran_ue_ngap_id);
......@@ -94,7 +94,7 @@ void UEAssociationLogicalNGConnectionItem::setRanUeNgapId(
//------------------------------------------------------------------------------
bool UEAssociationLogicalNGConnectionItem::getRanUeNgapId(
uint32_t& ran_ue_ngap_id) {
uint64_t& ran_ue_ngap_id) {
if (ranUeNgapId) {
ran_ue_ngap_id = ranUeNgapId->getRanUeNgapId();
return true;
......
......@@ -46,8 +46,8 @@ class UEAssociationLogicalNGConnectionItem {
void setAmfUeNgapId(unsigned long id);
bool getAmfUeNgapId(unsigned long& id);
void setRanUeNgapId(uint32_t id);
bool getRanUeNgapId(uint32_t& id);
void setRanUeNgapId(uint64_t id);
bool getRanUeNgapId(uint64_t& id);
bool encode(Ngap_UE_associatedLogicalNG_connectionItem_t& item);
bool encode(Ngap_UE_associatedLogicalNG_connectionItem_t* item);
......
......@@ -75,7 +75,7 @@ void DownLinkNasTransportMsg::setAmfUeNgapId(const unsigned long& id) {
}
//------------------------------------------------------------------------------
void DownLinkNasTransportMsg::setRanUeNgapId(const uint32_t& ran_ue_ngap_id) {
void DownLinkNasTransportMsg::setRanUeNgapId(const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_DownlinkNASTransport_IEs_t* ie =
......
......@@ -38,7 +38,7 @@ class DownLinkNasTransportMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setOldAmfName(const std::string name);
......
......@@ -70,7 +70,7 @@ void DownlinkRANStatusTransfer::setAmfUeNgapId(const unsigned long& id) {
}
//------------------------------------------------------------------------------
void DownlinkRANStatusTransfer::setRanUeNgapId(const uint32_t& id) {
void DownlinkRANStatusTransfer::setRanUeNgapId(const uint64_t& id) {
ranUeNgapId.setRanUeNgapId(id);
Ngap_DownlinkRANStatusTransferIEs_t* ie =
......
......@@ -36,7 +36,7 @@ class DownlinkRANStatusTransfer : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setRANStatusTransfer_TransparentContainer(
......
......@@ -73,7 +73,7 @@ void DownlinkUEAssociatedNRPPaTransportMsg::setAmfUeNgapId(
//------------------------------------------------------------------------------
void DownlinkUEAssociatedNRPPaTransportMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_DownlinkUEAssociatedNRPPaTransportIEs_t* ie =
......
......@@ -43,7 +43,7 @@ class DownlinkUEAssociatedNRPPaTransportMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setRoutingID(const OCTET_STRING_t& pdu);
......
......@@ -77,7 +77,7 @@ void HandoverCommandMsg::setAmfUeNgapId(const unsigned long& id) {
}
//------------------------------------------------------------------------------
void HandoverCommandMsg::setRanUeNgapId(const uint32_t& ran_ue_ngap_id) {
void HandoverCommandMsg::setRanUeNgapId(const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_HandoverCommandIEs_t* ie =
......
......@@ -45,7 +45,7 @@ class HandoverCommandMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setHandoverType(const long& type);
......
......@@ -65,7 +65,7 @@ void HandoverNotifyMsg::setAmfUeNgapId(const unsigned long& id) {
}
//------------------------------------------------------------------------------
void HandoverNotifyMsg::setRanUeNgapId(const uint32_t& ran_ue_ngap_id) {
void HandoverNotifyMsg::setRanUeNgapId(const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_HandoverNotifyIEs_t* ie =
......
......@@ -38,7 +38,7 @@ class HandoverNotifyMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setUserLocationInfoNR(const NrCgi_t& cig, const Tai_t& tai);
......
......@@ -73,7 +73,7 @@ void HandoverPreparationFailure::setAmfUeNgapId(const unsigned long& id) {
//------------------------------------------------------------------------------
void HandoverPreparationFailure::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_HandoverPreparationFailureIEs_t* ie =
......
......@@ -39,7 +39,7 @@ class HandoverPreparationFailure : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void getCause(Cause& cause) const;
......
......@@ -71,7 +71,7 @@ void HandoverRequestAck::setAmfUeNgapId(const unsigned long& id) {
}
//------------------------------------------------------------------------------
void HandoverRequestAck::setRanUeNgapId(const uint32_t& ran_ue_ngap_id) {
void HandoverRequestAck::setRanUeNgapId(const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_HandoverRequestAcknowledgeIEs_t* ie =
......
......@@ -40,7 +40,7 @@ class HandoverRequestAck : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setTargetToSource_TransparentContainer(
......
......@@ -68,7 +68,7 @@ void HandoverRequiredMsg::setAmfUeNgapId(const unsigned long& id) {
}
//------------------------------------------------------------------------------
void HandoverRequiredMsg::setRanUeNgapId(const uint32_t& ran_ue_ngap_id) {
void HandoverRequiredMsg::setRanUeNgapId(const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_HandoverRequiredIEs_t* ie = (Ngap_HandoverRequiredIEs_t*) calloc(
......
......@@ -43,7 +43,7 @@ class HandoverRequiredMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
Ngap_HandoverType_t getHandoverType();
......
......@@ -75,7 +75,7 @@ void InitialContextSetupFailureMsg::setAmfUeNgapId(const unsigned long& id) {
//------------------------------------------------------------------------------
void InitialContextSetupFailureMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_InitialContextSetupFailureIEs_t* ie =
......
......@@ -38,7 +38,7 @@ class InitialContextSetupFailureMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setPduSessionResourceFailedToSetupList(
......
......@@ -79,7 +79,7 @@ void InitialContextSetupRequestMsg::setAmfUeNgapId(const unsigned long& id) {
//------------------------------------------------------------------------------
void InitialContextSetupRequestMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_InitialContextSetupRequestIEs_t* ie =
......
......@@ -47,7 +47,7 @@ class InitialContextSetupRequestMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setOldAmfName(const std::string& name);
......
......@@ -73,7 +73,7 @@ void InitialContextSetupResponseMsg::setAmfUeNgapId(const unsigned long& id) {
//------------------------------------------------------------------------------
void InitialContextSetupResponseMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_InitialContextSetupResponseIEs_t* ie =
......
......@@ -40,7 +40,7 @@ class InitialContextSetupResponseMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setPduSessionResourceSetupResponseList(
......
......@@ -51,7 +51,7 @@ void InitialUEMessageMsg::initialize() {
}
//------------------------------------------------------------------------------
void InitialUEMessageMsg::setRanUENgapID(const uint32_t& value) {
void InitialUEMessageMsg::setRanUENgapID(const uint64_t& value) {
ranUeNgapId.setRanUeNgapId(value);
Ngap_InitialUEMessage_IEs_t* ie = (Ngap_InitialUEMessage_IEs_t*) calloc(
......@@ -310,7 +310,7 @@ bool InitialUEMessageMsg::decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) {
}
//------------------------------------------------------------------------------
bool InitialUEMessageMsg::getRanUENgapID(uint32_t& value) {
bool InitialUEMessageMsg::getRanUENgapID(uint64_t& value) {
value = ranUeNgapId.getRanUeNgapId();
return true;
}
......
......@@ -40,8 +40,8 @@ class InitialUEMessageMsg : public NgapMessage {
void initialize();
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngap_msg_pdu) override;
void setRanUENgapID(const uint32_t& value);
bool getRanUENgapID(uint32_t& value);
void setRanUENgapID(const uint64_t& value);
bool getRanUENgapID(uint64_t& value);
void setNasPdu(uint8_t* nas, size_t size);
bool getNasPdu(uint8_t*& nas, size_t& size);
......
......@@ -36,7 +36,7 @@ unsigned long NgapUEMessage::getAmfUeNgapId() {
}
//------------------------------------------------------------------------------
uint32_t NgapUEMessage::getRanUeNgapId() {
uint64_t NgapUEMessage::getRanUeNgapId() {
return ranUeNgapId.getRanUeNgapId();
}
......
......@@ -41,8 +41,8 @@ class NgapUEMessage : public NgapMessage {
virtual void setAmfUeNgapId(const unsigned long& id) = 0;
unsigned long getAmfUeNgapId();
virtual void setRanUeNgapId(const uint32_t& id) = 0;
uint32_t getRanUeNgapId();
virtual void setRanUeNgapId(const uint64_t& id) = 0;
uint64_t getRanUeNgapId();
protected:
AMF_UE_NGAP_ID amfUeNgapId;
......
......@@ -75,7 +75,7 @@ void PduSessionResourceModifyRequestMsg::setAmfUeNgapId(
//------------------------------------------------------------------------------
void PduSessionResourceModifyRequestMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_PDUSessionResourceModifyRequestIEs_t* ie =
......
......@@ -40,7 +40,7 @@ class PduSessionResourceModifyRequestMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setRanPagingPriority(const uint8_t& priority);
......
......@@ -76,7 +76,7 @@ void PduSessionResourceModifyResponseMsg::setAmfUeNgapId(
//------------------------------------------------------------------------------
void PduSessionResourceModifyResponseMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_PDUSessionResourceModifyResponseIEs_t* ie =
......
......@@ -39,7 +39,7 @@ class PduSessionResourceModifyResponseMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setPduSessionResourceModifyResponseList(
......
......@@ -78,7 +78,7 @@ void PduSessionResourceReleaseCommandMsg::setAmfUeNgapId(
//------------------------------------------------------------------------------
void PduSessionResourceReleaseCommandMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_PDUSessionResourceReleaseCommandIEs_t* ie =
......
......@@ -38,7 +38,7 @@ class PduSessionResourceReleaseCommandMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setRanPagingPriority(const uint8_t& priority);
......
......@@ -79,7 +79,7 @@ void PduSessionResourceReleaseResponseMsg::setAmfUeNgapId(
//------------------------------------------------------------------------------
void PduSessionResourceReleaseResponseMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_PDUSessionResourceReleaseResponseIEs_t* ie =
......
......@@ -37,7 +37,7 @@ class PduSessionResourceReleaseResponseMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setPduSessionResourceReleasedList(
......
......@@ -108,7 +108,7 @@ void PduSessionResourceSetupRequestMsg::setAmfUeNgapId(
//------------------------------------------------------------------------------
void PduSessionResourceSetupRequestMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_PDUSessionResourceSetupRequestIEs_t* ie =
......
......@@ -41,7 +41,7 @@ class PduSessionResourceSetupRequestMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setRanPagingPriority(const uint8_t& priority);
......
......@@ -77,7 +77,7 @@ void PduSessionResourceSetupResponseMsg::setAmfUeNgapId(
//------------------------------------------------------------------------------
void PduSessionResourceSetupResponseMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_PDUSessionResourceSetupResponseIEs_t* ie =
......
......@@ -40,7 +40,7 @@ class PduSessionResourceSetupResponseMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setPduSessionResourceSetupResponseList(
......
......@@ -80,7 +80,7 @@ unsigned long RerouteNASRequest::getAmfUeNgapId() {
}
//------------------------------------------------------------------------------
void RerouteNASRequest::setRanUeNgapId(const uint32_t& ran_ue_ngap_id) {
void RerouteNASRequest::setRanUeNgapId(const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_RerouteNASRequest_IEs_t* ie = (Ngap_RerouteNASRequest_IEs_t*) calloc(
......@@ -101,7 +101,7 @@ void RerouteNASRequest::setRanUeNgapId(const uint32_t& ran_ue_ngap_id) {
}
//------------------------------------------------------------------------------
uint32_t RerouteNASRequest::getRanUeNgapId() {
uint64_t RerouteNASRequest::getRanUeNgapId() {
return ranUeNgapId.getRanUeNgapId();
}
......
......@@ -44,8 +44,8 @@ class RerouteNASRequest : public NgapMessage {
unsigned long getAmfUeNgapId();
void getAmfUeNgapId(std::string& amf_set_id);
void setRanUeNgapId(const uint32_t& id); // 32 bits
uint32_t getRanUeNgapId();
void setRanUeNgapId(const uint64_t& id); // 32 bits
uint64_t getRanUeNgapId();
void setNgapMessage(const OCTET_STRING_t& message);
bool getNgapMessage(OCTET_STRING_t& message) const;
......
......@@ -67,7 +67,7 @@ void UEContextReleaseCompleteMsg::setAmfUeNgapId(const unsigned long& id) {
//------------------------------------------------------------------------------
void UEContextReleaseCompleteMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_UEContextReleaseComplete_IEs* ie =
(Ngap_UEContextReleaseComplete_IEs*) calloc(
......
......@@ -38,7 +38,7 @@ class UEContextReleaseCompleteMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setUserLocationInfoNR(const NrCgi_t& cig, const Tai_t& tai);
......
......@@ -65,7 +65,7 @@ void UEContextReleaseRequestMsg::setAmfUeNgapId(const unsigned long& id) {
//------------------------------------------------------------------------------
void UEContextReleaseRequestMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_UEContextReleaseRequest_IEs* ie =
(Ngap_UEContextReleaseRequest_IEs*) calloc(
......
......@@ -39,7 +39,7 @@ class UEContextReleaseRequestMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void addCauseIE();
......
......@@ -75,7 +75,7 @@ void UeRadioCapabilityInfoIndicationMsg::setAmfUeNgapId(
//------------------------------------------------------------------------------
void UeRadioCapabilityInfoIndicationMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_UERadioCapabilityInfoIndicationIEs_t* ie =
......
......@@ -39,7 +39,7 @@ class UeRadioCapabilityInfoIndicationMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setUERadioCapability(uint8_t* buf, size_t size);
......
......@@ -67,7 +67,7 @@ void UplinkNASTransportMsg::setAmfUeNgapId(const unsigned long& id) {
}
//------------------------------------------------------------------------------
void UplinkNASTransportMsg::setRanUeNgapId(const uint32_t& ran_ue_ngap_id) {
void UplinkNASTransportMsg::setRanUeNgapId(const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_UplinkNASTransport_IEs_t* ie = (Ngap_UplinkNASTransport_IEs_t*) calloc(
......
......@@ -40,7 +40,7 @@ class UplinkNASTransportMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setNasPdu(uint8_t* nas, size_t sizeofnas);
......
......@@ -69,7 +69,7 @@ void UplinkRANStatusTransfer::setAmfUeNgapId(const unsigned long& id) {
}
//------------------------------------------------------------------------------
void UplinkRANStatusTransfer::setRanUeNgapId(const uint32_t& ran_ue_ngap_id) {
void UplinkRANStatusTransfer::setRanUeNgapId(const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_UplinkRANStatusTransferIEs_t* ie =
......
......@@ -38,7 +38,7 @@ class UplinkRANStatusTransfer : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void getRANStatusTransfer_TransparentContainer(
......
......@@ -73,7 +73,7 @@ void UplinkUEAssociatedNRPPaTransportMsg::setAmfUeNgapId(
//------------------------------------------------------------------------------
void UplinkUEAssociatedNRPPaTransportMsg::setRanUeNgapId(
const uint32_t& ran_ue_ngap_id) {
const uint64_t& ran_ue_ngap_id) {
ranUeNgapId.setRanUeNgapId(ran_ue_ngap_id);
Ngap_UplinkUEAssociatedNRPPaTransportIEs_t* ie =
......
......@@ -38,7 +38,7 @@ class UplinkUEAssociatedNRPPaTransportMsg : public NgapUEMessage {
void initialize();
void setAmfUeNgapId(const unsigned long& id) override;
void setRanUeNgapId(const uint32_t& id) override;
void setRanUeNgapId(const uint64_t& id) override;
bool decodeFromPdu(Ngap_NGAP_PDU_t* ngapMsgPdu) override;
void setRoutingID(const OCTET_STRING_t& pdu);
......
......@@ -177,6 +177,7 @@ int sctp_server::sctp_read_from_socket(int sd, uint32_t ppid) {
Logger::sctp().error("sctp_recvmsg error:: %s:%d", strerror(errno), errno);
return SCTP_RC_ERROR;
}
//第一次连接,将连接入队,创建gnb_context
if (flags & MSG_NOTIFICATION) {
union sctp_notification* snp = (union sctp_notification*) buffer;
switch (snp->sn_header.sn_type) {
......@@ -195,13 +196,16 @@ int sctp_server::sctp_read_from_socket(int sd, uint32_t ppid) {
break;
}
}
} else {
} else {//此后的非基站连接
sctp_association_t* association;
//连接队列中查找 没找到报错
if ((association = sctp_is_assoc_in_list(
(sctp_assoc_id_t) sinfo.sinfo_assoc_id)) == NULL) {
return SCTP_RC_ERROR;
}
association->messages_recv++;
Logger::sctp().debug(
" messages_recv = %d ", association->messages_recv);
if (ntohl(sinfo.sinfo_ppid) != association->ppid) {
Logger::sctp().error(
"Received data from peer with unsolicited PPID (%d), expecting (%d)",
......@@ -432,6 +436,9 @@ int sctp_server::sctp_send_msg(
"Successfully sent %d bytes on stream %d", blength(*payload), stream);
*payload = NULL;
assoc_desc->messages_sent++;
Logger::sctp().debug(
" messages_sent = %d ", assoc_desc->messages_sent);
return 0;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment