Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG-RAN
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
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-RAN
Commits
9b143e9a
Commit
9b143e9a
authored
Feb 15, 2019
by
Raphael Defosseux
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
CI: astyle to help merge
Signed-off-by:
Raphael Defosseux
<
raphael.defosseux@eurecom.fr
>
parent
ee3b6509
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
49 additions
and
75 deletions
+49
-75
openair3/S1AP/s1ap_eNB_handlers.c
openair3/S1AP/s1ap_eNB_handlers.c
+49
-75
No files found.
openair3/S1AP/s1ap_eNB_handlers.c
View file @
9b143e9a
...
@@ -96,13 +96,13 @@ int s1ap_eNB_handle_e_rab_release_command(uint32_t assoc_id,
...
@@ -96,13 +96,13 @@ int s1ap_eNB_handle_e_rab_release_command(uint32_t assoc_id,
static
static
int
s1ap_eNB_handle_s1_path_switch_request_ack
(
uint32_t
assoc_id
,
int
s1ap_eNB_handle_s1_path_switch_request_ack
(
uint32_t
assoc_id
,
uint32_t
stream
,
uint32_t
stream
,
S1AP_S1AP_PDU_t
*
pdu
);
S1AP_S1AP_PDU_t
*
pdu
);
static
static
int
s1ap_eNB_handle_s1_path_switch_request_failure
(
uint32_t
assoc_id
,
int
s1ap_eNB_handle_s1_path_switch_request_failure
(
uint32_t
assoc_id
,
uint32_t
stream
,
uint32_t
stream
,
S1AP_S1AP_PDU_t
*
pdu
);
S1AP_S1AP_PDU_t
*
pdu
);
/* Handlers matrix. Only eNB related procedure present here */
/* Handlers matrix. Only eNB related procedure present here */
s1ap_message_decoded_callback
messages_callback
[][
3
]
=
{
s1ap_message_decoded_callback
messages_callback
[][
3
]
=
{
...
@@ -781,9 +781,7 @@ int s1ap_eNB_handle_initial_context_request(uint32_t assoc_id,
...
@@ -781,9 +781,7 @@ int s1ap_eNB_handle_initial_context_request(uint32_t assoc_id,
S1AP_INITIAL_CONTEXT_SETUP_REQ
(
message_p
).
ue_initial_id
=
ue_desc_p
->
ue_initial_id
;
S1AP_INITIAL_CONTEXT_SETUP_REQ
(
message_p
).
ue_initial_id
=
ue_desc_p
->
ue_initial_id
;
ue_desc_p
->
ue_initial_id
=
0
;
ue_desc_p
->
ue_initial_id
=
0
;
S1AP_INITIAL_CONTEXT_SETUP_REQ
(
message_p
).
eNB_ue_s1ap_id
=
ue_desc_p
->
eNB_ue_s1ap_id
;
S1AP_INITIAL_CONTEXT_SETUP_REQ
(
message_p
).
eNB_ue_s1ap_id
=
ue_desc_p
->
eNB_ue_s1ap_id
;
S1AP_INITIAL_CONTEXT_SETUP_REQ
(
message_p
).
mme_ue_s1ap_id
=
ue_desc_p
->
mme_ue_s1ap_id
;
S1AP_INITIAL_CONTEXT_SETUP_REQ
(
message_p
).
mme_ue_s1ap_id
=
ue_desc_p
->
mme_ue_s1ap_id
;
/* id-uEaggregateMaximumBitrate */
/* id-uEaggregateMaximumBitrate */
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_InitialContextSetupRequestIEs_t
,
ie
,
container
,
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_InitialContextSetupRequestIEs_t
,
ie
,
container
,
S1AP_ProtocolIE_ID_id_uEaggregateMaximumBitrate
,
true
);
S1AP_ProtocolIE_ID_id_uEaggregateMaximumBitrate
,
true
);
...
@@ -1387,26 +1385,20 @@ int s1ap_eNB_handle_e_rab_release_command(uint32_t assoc_id,
...
@@ -1387,26 +1385,20 @@ int s1ap_eNB_handle_e_rab_release_command(uint32_t assoc_id,
static
static
int
s1ap_eNB_handle_s1_path_switch_request_ack
(
uint32_t
assoc_id
,
int
s1ap_eNB_handle_s1_path_switch_request_ack
(
uint32_t
assoc_id
,
uint32_t
stream
,
uint32_t
stream
,
S1AP_S1AP_PDU_t
*
pdu
)
S1AP_S1AP_PDU_t
*
pdu
)
{
{
s1ap_eNB_mme_data_t
*
mme_desc_p
=
NULL
;
s1ap_eNB_mme_data_t
*
mme_desc_p
=
NULL
;
s1ap_eNB_ue_context_t
*
ue_desc_p
=
NULL
;
s1ap_eNB_ue_context_t
*
ue_desc_p
=
NULL
;
MessageDef
*
message_p
=
NULL
;
MessageDef
*
message_p
=
NULL
;
S1AP_PathSwitchRequestAcknowledge_t
*
pathSwitchRequestAcknowledge
;
S1AP_PathSwitchRequestAcknowledge_t
*
pathSwitchRequestAcknowledge
;
S1AP_PathSwitchRequestAcknowledgeIEs_t
*
ie
;
S1AP_PathSwitchRequestAcknowledgeIEs_t
*
ie
;
S1AP_E_RABToBeSwitchedULItemIEs_t
*
s1ap_E_RABToBeSwitchedULItemIEs
;
S1AP_E_RABToBeSwitchedULItemIEs_t
*
s1ap_E_RABToBeSwitchedULItemIEs
;
S1AP_E_RABToBeSwitchedULItem_t
*
s1ap_E_RABToBeSwitchedULItem
;
S1AP_E_RABToBeSwitchedULItem_t
*
s1ap_E_RABToBeSwitchedULItem
;
S1AP_E_RABItemIEs_t
*
e_RABItemIEs
;
S1AP_E_RABItemIEs_t
*
e_RABItemIEs
;
S1AP_E_RABItem_t
*
e_RABItem
;
S1AP_E_RABItem_t
*
e_RABItem
;
DevAssert
(
pdu
!=
NULL
);
DevAssert
(
pdu
!=
NULL
);
pathSwitchRequestAcknowledge
=
&
pdu
->
choice
.
successfulOutcome
.
value
.
choice
.
PathSwitchRequestAcknowledge
;
pathSwitchRequestAcknowledge
=
&
pdu
->
choice
.
successfulOutcome
.
value
.
choice
.
PathSwitchRequestAcknowledge
;
/* Path Switch request == UE-related procedure -> stream !=0 */
/* Path Switch request == UE-related procedure -> stream !=0 */
if
(
stream
==
0
)
{
if
(
stream
==
0
)
{
S1AP_ERROR
(
"[SCTP %d] Received s1 path switch request ack on stream (%d)
\n
"
,
S1AP_ERROR
(
"[SCTP %d] Received s1 path switch request ack on stream (%d)
\n
"
,
...
@@ -1422,11 +1414,9 @@ int s1ap_eNB_handle_s1_path_switch_request_ack(uint32_t assoc_id,
...
@@ -1422,11 +1414,9 @@ int s1ap_eNB_handle_s1_path_switch_request_ack(uint32_t assoc_id,
// send a message to RRC
// send a message to RRC
message_p
=
itti_alloc_new_message
(
TASK_S1AP
,
S1AP_PATH_SWITCH_REQ_ACK
);
message_p
=
itti_alloc_new_message
(
TASK_S1AP
,
S1AP_PATH_SWITCH_REQ_ACK
);
/* mandatory */
/* mandatory */
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_ProtocolIE_ID_id_eNB_UE_S1AP_ID
,
true
);
S1AP_ProtocolIE_ID_id_eNB_UE_S1AP_ID
,
true
);
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
eNB_ue_s1ap_id
=
ie
->
value
.
choice
.
ENB_UE_S1AP_ID
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
eNB_ue_s1ap_id
=
ie
->
value
.
choice
.
ENB_UE_S1AP_ID
;
if
((
ue_desc_p
=
s1ap_eNB_get_ue_context
(
mme_desc_p
->
s1ap_eNB_instance
,
if
((
ue_desc_p
=
s1ap_eNB_get_ue_context
(
mme_desc_p
->
s1ap_eNB_instance
,
...
@@ -1438,94 +1428,79 @@ int s1ap_eNB_handle_s1_path_switch_request_ack(uint32_t assoc_id,
...
@@ -1438,94 +1428,79 @@ int s1ap_eNB_handle_s1_path_switch_request_ack(uint32_t assoc_id,
}
}
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
ue_initial_id
=
ue_desc_p
->
ue_initial_id
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
ue_initial_id
=
ue_desc_p
->
ue_initial_id
;
/* mandatory */
/* mandatory */
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_ProtocolIE_ID_id_MME_UE_S1AP_ID
,
true
);
S1AP_ProtocolIE_ID_id_MME_UE_S1AP_ID
,
true
);
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
mme_ue_s1ap_id
=
ie
->
value
.
choice
.
MME_UE_S1AP_ID
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
mme_ue_s1ap_id
=
ie
->
value
.
choice
.
MME_UE_S1AP_ID
;
if
(
ue_desc_p
->
mme_ue_s1ap_id
!=
ie
->
value
.
choice
.
MME_UE_S1AP_ID
){
if
(
ue_desc_p
->
mme_ue_s1ap_id
!=
ie
->
value
.
choice
.
MME_UE_S1AP_ID
)
{
S1AP_WARN
(
"UE context mme_ue_s1ap_id is different form that of the message (%d != %ld)"
,
S1AP_WARN
(
"UE context mme_ue_s1ap_id is different form that of the message (%d != %ld)"
,
ue_desc_p
->
mme_ue_s1ap_id
,
ie
->
value
.
choice
.
MME_UE_S1AP_ID
);
ue_desc_p
->
mme_ue_s1ap_id
,
ie
->
value
.
choice
.
MME_UE_S1AP_ID
);
}
}
/* mandatory */
/* mandatory */
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_ProtocolIE_ID_id_SecurityContext
,
true
);
S1AP_ProtocolIE_ID_id_SecurityContext
,
true
);
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
next_hop_chain_count
=
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
next_hop_chain_count
=
ie
->
value
.
choice
.
SecurityContext
.
nextHopChainingCount
;
ie
->
value
.
choice
.
SecurityContext
.
nextHopChainingCount
;
memcpy
(
&
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
next_security_key
,
memcpy
(
&
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
next_security_key
,
ie
->
value
.
choice
.
SecurityContext
.
nextHopParameter
.
buf
,
ie
->
value
.
choice
.
SecurityContext
.
nextHopParameter
.
buf
,
ie
->
value
.
choice
.
SecurityContext
.
nextHopParameter
.
size
);
ie
->
value
.
choice
.
SecurityContext
.
nextHopParameter
.
size
);
/* optional */
/* optional */
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_ProtocolIE_ID_id_uEaggregateMaximumBitrate
,
false
);
S1AP_ProtocolIE_ID_id_uEaggregateMaximumBitrate
,
false
);
if
(
ie
)
{
if
(
ie
)
{
OCTET_STRING_TO_INT32
(
OCTET_STRING_TO_INT32
(
&
ie
->
value
.
choice
.
UEAggregateMaximumBitrate
.
uEaggregateMaximumBitRateUL
,
&
ie
->
value
.
choice
.
UEAggregateMaximumBitrate
.
uEaggregateMaximumBitRateUL
,
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
ue_ambr
.
br_ul
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
ue_ambr
.
br_ul
);
);
OCTET_STRING_TO_INT32
(
OCTET_STRING_TO_INT32
(
&
ie
->
value
.
choice
.
UEAggregateMaximumBitrate
.
uEaggregateMaximumBitRateDL
,
&
ie
->
value
.
choice
.
UEAggregateMaximumBitrate
.
uEaggregateMaximumBitRateDL
,
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
ue_ambr
.
br_dl
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
ue_ambr
.
br_dl
);
);
}
else
{
}
else
{
S1AP_WARN
(
"UEAggregateMaximumBitrate not supported
\n
"
);
S1AP_WARN
(
"UEAggregateMaximumBitrate not supported
\n
"
);
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
ue_ambr
.
br_ul
=
0
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
ue_ambr
.
br_ul
=
0
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
ue_ambr
.
br_dl
=
0
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
ue_ambr
.
br_dl
=
0
;
}
}
/* optional */
/* optional */
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_ProtocolIE_ID_id_E_RABToBeSwitchedULList
,
false
);
S1AP_ProtocolIE_ID_id_E_RABToBeSwitchedULList
,
false
);
if
(
ie
)
{
if
(
ie
)
{
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
nb_e_rabs_tobeswitched
=
ie
->
value
.
choice
.
E_RABToBeSwitchedULList
.
list
.
count
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
nb_e_rabs_tobeswitched
=
ie
->
value
.
choice
.
E_RABToBeSwitchedULList
.
list
.
count
;
for
(
int
i
=
0
;
i
<
ie
->
value
.
choice
.
E_RABToBeSwitchedULList
.
list
.
count
;
i
++
)
{
for
(
int
i
=
0
;
i
<
ie
->
value
.
choice
.
E_RABToBeSwitchedULList
.
list
.
count
;
i
++
)
{
s1ap_E_RABToBeSwitchedULItemIEs
=
(
S1AP_E_RABToBeSwitchedULItemIEs_t
*
)
ie
->
value
.
choice
.
E_RABToBeSwitchedULList
.
list
.
array
[
i
];
s1ap_E_RABToBeSwitchedULItemIEs
=
(
S1AP_E_RABToBeSwitchedULItemIEs_t
*
)
ie
->
value
.
choice
.
E_RABToBeSwitchedULList
.
list
.
array
[
i
];
s1ap_E_RABToBeSwitchedULItem
=
&
s1ap_E_RABToBeSwitchedULItemIEs
->
value
.
choice
.
E_RABToBeSwitchedULItem
;
s1ap_E_RABToBeSwitchedULItem
=
&
s1ap_E_RABToBeSwitchedULItemIEs
->
value
.
choice
.
E_RABToBeSwitchedULItem
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
e_rabs_tobeswitched
[
i
].
e_rab_id
=
s1ap_E_RABToBeSwitchedULItem
->
e_RAB_ID
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
e_rabs_tobeswitched
[
i
].
e_rab_id
=
s1ap_E_RABToBeSwitchedULItem
->
e_RAB_ID
;
memcpy
(
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
e_rabs_tobeswitched
[
i
].
sgw_addr
.
buffer
,
memcpy
(
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
e_rabs_tobeswitched
[
i
].
sgw_addr
.
buffer
,
s1ap_E_RABToBeSwitchedULItem
->
transportLayerAddress
.
buf
,
s1ap_E_RABToBeSwitchedULItem
->
transportLayerAddress
.
size
);
s1ap_E_RABToBeSwitchedULItem
->
transportLayerAddress
.
buf
,
s1ap_E_RABToBeSwitchedULItem
->
transportLayerAddress
.
size
);
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
e_rabs_tobeswitched
[
i
].
sgw_addr
.
length
=
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
e_rabs_tobeswitched
[
i
].
sgw_addr
.
length
=
s1ap_E_RABToBeSwitchedULItem
->
transportLayerAddress
.
size
*
8
-
s1ap_E_RABToBeSwitchedULItem
->
transportLayerAddress
.
bits_unused
;
s1ap_E_RABToBeSwitchedULItem
->
transportLayerAddress
.
size
*
8
-
s1ap_E_RABToBeSwitchedULItem
->
transportLayerAddress
.
bits_unused
;
OCTET_STRING_TO_INT32
(
&
s1ap_E_RABToBeSwitchedULItem
->
gTP_TEID
,
OCTET_STRING_TO_INT32
(
&
s1ap_E_RABToBeSwitchedULItem
->
gTP_TEID
,
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
e_rabs_tobeswitched
[
i
].
gtp_teid
);
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
e_rabs_tobeswitched
[
i
].
gtp_teid
);
}
}
}
}
else
{
else
{
S1AP_WARN
(
"E_RABToBeSwitchedULList not supported
\n
"
);
S1AP_WARN
(
"E_RABToBeSwitchedULList not supported
\n
"
);
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
nb_e_rabs_tobeswitched
=
0
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
nb_e_rabs_tobeswitched
=
0
;
}
}
/* optional */
/* optional */
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_ProtocolIE_ID_id_E_RABToBeReleasedList
,
false
);
S1AP_ProtocolIE_ID_id_E_RABToBeReleasedList
,
false
);
if
(
ie
)
{
if
(
ie
)
{
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
nb_e_rabs_tobereleased
=
ie
->
value
.
choice
.
E_RABList
.
list
.
count
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
nb_e_rabs_tobereleased
=
ie
->
value
.
choice
.
E_RABList
.
list
.
count
;
for
(
int
i
=
0
;
i
<
ie
->
value
.
choice
.
E_RABList
.
list
.
count
;
i
++
)
{
for
(
int
i
=
0
;
i
<
ie
->
value
.
choice
.
E_RABList
.
list
.
count
;
i
++
)
{
e_RABItemIEs
=
(
S1AP_E_RABItemIEs_t
*
)
ie
->
value
.
choice
.
E_RABList
.
list
.
array
[
i
];
e_RABItemIEs
=
(
S1AP_E_RABItemIEs_t
*
)
ie
->
value
.
choice
.
E_RABList
.
list
.
array
[
i
];
e_RABItem
=
&
e_RABItemIEs
->
value
.
choice
.
E_RABItem
;
e_RABItem
=
&
e_RABItemIEs
->
value
.
choice
.
E_RABItem
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
e_rabs_tobereleased
[
i
].
e_rab_id
=
e_RABItem
->
e_RAB_ID
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
e_rabs_tobereleased
[
i
].
e_rab_id
=
e_RABItem
->
e_RAB_ID
;
}
}
}
}
else
{
else
{
S1AP_WARN
(
"E_RABToBeReleasedList not supported
\n
"
);
S1AP_WARN
(
"E_RABToBeReleasedList not supported
\n
"
);
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
nb_e_rabs_tobereleased
=
0
;
S1AP_PATH_SWITCH_REQ_ACK
(
message_p
).
nb_e_rabs_tobereleased
=
0
;
}
}
...
@@ -1533,6 +1508,7 @@ int s1ap_eNB_handle_s1_path_switch_request_ack(uint32_t assoc_id,
...
@@ -1533,6 +1508,7 @@ int s1ap_eNB_handle_s1_path_switch_request_ack(uint32_t assoc_id,
/* optional */
/* optional */
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_ProtocolIE_ID_id_CriticalityDiagnostics
,
false
);
S1AP_ProtocolIE_ID_id_CriticalityDiagnostics
,
false
);
if
(
!
ie
)
{
if
(
!
ie
)
{
S1AP_WARN
(
"Critical Diagnostic not supported
\n
"
);
S1AP_WARN
(
"Critical Diagnostic not supported
\n
"
);
}
}
...
@@ -1540,30 +1516,24 @@ int s1ap_eNB_handle_s1_path_switch_request_ack(uint32_t assoc_id,
...
@@ -1540,30 +1516,24 @@ int s1ap_eNB_handle_s1_path_switch_request_ack(uint32_t assoc_id,
/* optional */
/* optional */
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestAcknowledgeIEs_t
,
ie
,
pathSwitchRequestAcknowledge
,
S1AP_ProtocolIE_ID_id_MME_UE_S1AP_ID_2
,
false
);
S1AP_ProtocolIE_ID_id_MME_UE_S1AP_ID_2
,
false
);
if
(
!
ie
)
{
if
(
!
ie
)
{
S1AP_WARN
(
"MME_UE_S1AP_ID_2 flag not supported
\n
"
);
S1AP_WARN
(
"MME_UE_S1AP_ID_2 flag not supported
\n
"
);
}
}
// TODO continue
// TODO continue
itti_send_msg_to_task
(
TASK_RRC_ENB
,
ue_desc_p
->
eNB_instance
->
instance
,
message_p
);
itti_send_msg_to_task
(
TASK_RRC_ENB
,
ue_desc_p
->
eNB_instance
->
instance
,
message_p
);
return
0
;
return
0
;
}
}
static
static
int
s1ap_eNB_handle_s1_path_switch_request_failure
(
uint32_t
assoc_id
,
int
s1ap_eNB_handle_s1_path_switch_request_failure
(
uint32_t
assoc_id
,
uint32_t
stream
,
uint32_t
stream
,
S1AP_S1AP_PDU_t
*
pdu
)
S1AP_S1AP_PDU_t
*
pdu
)
{
{
s1ap_eNB_mme_data_t
*
mme_desc_p
=
NULL
;
s1ap_eNB_mme_data_t
*
mme_desc_p
=
NULL
;
S1AP_PathSwitchRequestFailure_t
*
pathSwitchRequestFailure
;
S1AP_PathSwitchRequestFailure_t
*
pathSwitchRequestFailure
;
S1AP_PathSwitchRequestFailureIEs_t
*
ie
;
S1AP_PathSwitchRequestFailureIEs_t
*
ie
;
DevAssert
(
pdu
!=
NULL
);
DevAssert
(
pdu
!=
NULL
);
pathSwitchRequestFailure
=
&
pdu
->
choice
.
unsuccessfulOutcome
.
value
.
choice
.
PathSwitchRequestFailure
;
pathSwitchRequestFailure
=
&
pdu
->
choice
.
unsuccessfulOutcome
.
value
.
choice
.
PathSwitchRequestFailure
;
if
(
stream
!=
0
)
{
if
(
stream
!=
0
)
{
...
@@ -1582,24 +1552,29 @@ int s1ap_eNB_handle_s1_path_switch_request_failure(uint32_t assoc_
...
@@ -1582,24 +1552,29 @@ int s1ap_eNB_handle_s1_path_switch_request_failure(uint32_t assoc_
S1AP_ProtocolIE_ID_id_Cause
,
true
);
S1AP_ProtocolIE_ID_id_Cause
,
true
);
switch
(
ie
->
value
.
choice
.
Cause
.
present
)
{
switch
(
ie
->
value
.
choice
.
Cause
.
present
)
{
case
S1AP_Cause_PR_NOTHING
:
case
S1AP_Cause_PR_NOTHING
:
S1AP_WARN
(
"Received S1 Error indication cause NOTHING
\n
"
);
S1AP_WARN
(
"Received S1 Error indication cause NOTHING
\n
"
);
break
;
break
;
case
S1AP_Cause_PR_radioNetwork
:
S1AP_WARN
(
"Radio Network Layer Cause Failure
\n
"
);
case
S1AP_Cause_PR_radioNetwork
:
break
;
S1AP_WARN
(
"Radio Network Layer Cause Failure
\n
"
);
case
S1AP_Cause_PR_transport
:
break
;
S1AP_WARN
(
"Transport Layer Cause Failure
\n
"
);
break
;
case
S1AP_Cause_PR_transport
:
case
S1AP_Cause_PR_nas
:
S1AP_WARN
(
"Transport Layer Cause Failure
\n
"
);
S1AP_WARN
(
"NAS Cause Failure
\n
"
);
break
;
break
;
case
S1AP_Cause_PR_misc
:
case
S1AP_Cause_PR_nas
:
S1AP_WARN
(
"Miscelaneous Cause Failure
\n
"
);
S1AP_WARN
(
"NAS Cause Failure
\n
"
);
break
;
break
;
default:
S1AP_WARN
(
"Received an unknown S1 Error indication cause
\n
"
);
case
S1AP_Cause_PR_misc
:
break
;
S1AP_WARN
(
"Miscelaneous Cause Failure
\n
"
);
break
;
default:
S1AP_WARN
(
"Received an unknown S1 Error indication cause
\n
"
);
break
;
}
}
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestFailureIEs_t
,
ie
,
pathSwitchRequestFailure
,
S1AP_FIND_PROTOCOLIE_BY_ID
(
S1AP_PathSwitchRequestFailureIEs_t
,
ie
,
pathSwitchRequestFailure
,
...
@@ -1608,8 +1583,7 @@ int s1ap_eNB_handle_s1_path_switch_request_failure(uint32_t assoc_
...
@@ -1608,8 +1583,7 @@ int s1ap_eNB_handle_s1_path_switch_request_failure(uint32_t assoc_
if
(
!
ie
)
{
if
(
!
ie
)
{
S1AP_WARN
(
"Critical Diagnostic not supported
\n
"
);
S1AP_WARN
(
"Critical Diagnostic not supported
\n
"
);
}
}
// TODO continue
// TODO continue
return
0
;
return
0
;
}
}
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