Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-AMF
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenXG
OpenXG-AMF
Commits
3b2bda13
Commit
3b2bda13
authored
Mar 04, 2021
by
Tien-Thinh Nguyen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Finish SCTP Shutdown/Reset event handling
parent
dd78d295
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
6 additions
and
40 deletions
+6
-40
src/amf-app/amf_n2.cpp
src/amf-app/amf_n2.cpp
+1
-1
src/ngap/ngapMsgs/NGReset.cpp
src/ngap/ngapMsgs/NGReset.cpp
+3
-4
src/ngap/ngapMsgs/NGReset.hpp
src/ngap/ngapMsgs/NGReset.hpp
+0
-2
src/ngap/ngap_app/ngap_app.cpp
src/ngap/ngap_app/ngap_app.cpp
+2
-33
No files found.
src/amf-app/amf_n2.cpp
View file @
3b2bda13
...
...
@@ -416,7 +416,7 @@ void amf_n2::handle_itti_message(itti_ng_shutdown& itti_msg) {
gc
.
get
()
->
ng_state
=
NGAP_SHUTDOWN
;
//
r
elease all the resources related to this interface
//
R
elease all the resources related to this interface
for
(
auto
ue_context
:
ranid2uecontext
)
{
if
(
ue_context
.
second
->
gnb_assoc_id
==
itti_msg
.
assoc_id
)
{
uint32_t
ran_ue_ngap_id
=
ue_context
.
second
->
ran_ue_ngap_id
;
...
...
src/ngap/ngapMsgs/NGReset.cpp
View file @
3b2bda13
...
...
@@ -49,9 +49,8 @@ namespace ngap {
NGResetMsg
::
NGResetMsg
()
{
ngResetPdu
=
nullptr
;
ngResetIEs
=
nullptr
;
// cause = {};
cause
=
nullptr
;
resetType
=
nullptr
;
cause
=
nullptr
;
resetType
=
nullptr
;
}
//------------------------------------------------------------------------------
NGResetMsg
::~
NGResetMsg
()
{}
...
...
@@ -74,7 +73,7 @@ void NGResetMsg::setMessageType() {
NgResetMessageTypeIE
.
encode2pdu
(
ngResetPdu
);
ngResetIEs
=
&
(
ngResetPdu
->
choice
.
initiatingMessage
->
value
.
choice
.
NGReset
);
}
else
{
cout
<<
"[
w
arning] This information doesn't refer to NGReset "
cout
<<
"[
W
arning] This information doesn't refer to NGReset "
"Message!!!"
<<
endl
;
}
...
...
src/ngap/ngapMsgs/NGReset.hpp
View file @
3b2bda13
...
...
@@ -61,8 +61,6 @@ class NGResetMsg {
private:
Ngap_NGAP_PDU_t
*
ngResetPdu
;
Ngap_NGReset_t
*
ngResetIEs
;
// Ngap_Cause_t cause;
// Ngap_ResetType_t resetType;
Cause
*
cause
;
ResetType
*
resetType
;
...
...
src/ngap/ngap_app/ngap_app.cpp
View file @
3b2bda13
...
...
@@ -116,39 +116,8 @@ void ngap_app::handle_sctp_shutdown(sctp_assoc_id_t assoc_id) {
Logger
::
ngap
().
debug
(
"Handle a SCTP Shutdown event (association id: %d)"
,
assoc_id
);
// remove all the context
/*
for (auto ue_context : ranid2uecontext) {
if (ue_context.second->gnb_assoc_id == itti_msg.assoc_id) {
uint32_t ran_ue_ngap_id = ue_context.second->ran_ue_ngap_id;
long amf_ue_ngap_id = ue_context.second->amf_ue_ngap_id;
// get NAS context
std::shared_ptr<nas_context> nc;
if (amf_n1_inst->is_amf_ue_id_2_nas_context(amf_ue_ngap_id))
nc = amf_n1_inst->amf_ue_id_2_nas_context(amf_ue_ngap_id);
else {
Logger::amf_n2().warn(
"No existed nas_context with amf_ue_ngap_id(0x%x)",
amf_ue_ngap_id);
}
stacs.update_5gmm_state(nc.get()->imsi, "5GMM-DEREGISTERED");
}
}
*/
// delete gNB context
Logger
::
ngap
().
debug
(
"Remove gNB Context %d"
,
assoc_id
);
remove_gnb_context
(
assoc_id
);
/*
stacs.gnbs.erase(gc.get()->globalRanNodeId);
Logger::amf_n2().debug(
"Remove gNB with globalRanNodeId 0x%x", gc.get()->globalRanNodeId);
stacs.gNB_connected -= 1;
stacs.display();
*/
// Handle the message
(
*
events_callback
[
1
])(
assoc_id
);
(
*
events_callback
[
0
])(
assoc_id
);
}
//------------------------------------------------------------------------------
...
...
@@ -200,5 +169,5 @@ void ngap_app::set_gnb_id_2_gnb_context(
//------------------------------------------------------------------------------
void
ngap_app
::
remove_gnb_context
(
const
long
&
gnb_id
)
{
std
::
unique_lock
lock
(
m_gnbid2gnbContext
);
gnbid2gnbContext
.
erase
(
gnb_id
);
if
(
is_gnb_id_2_gnb_context
(
gnb_id
))
gnbid2gnbContext
.
erase
(
gnb_id
);
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment