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
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
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-RAN
Commits
15cd202d
Commit
15cd202d
authored
Sep 15, 2020
by
zhenghuangkun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add UERadioCapabilityInfoIndication
parent
ef508433
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
19 deletions
+18
-19
openair3/NGAP/ngap_gNB_nas_procedures.c
openair3/NGAP/ngap_gNB_nas_procedures.c
+18
-19
No files found.
openair3/NGAP/ngap_gNB_nas_procedures.c
View file @
15cd202d
...
@@ -861,12 +861,11 @@ int ngap_gNB_ue_capabilities(instance_t instance,
...
@@ -861,12 +861,11 @@ int ngap_gNB_ue_capabilities(instance_t instance,
ngap_ue_cap_info_ind_t
*
ue_cap_info_ind_p
)
ngap_ue_cap_info_ind_t
*
ue_cap_info_ind_p
)
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
{
{
#if 0
ngap_gNB_instance_t
*
ngap_gNB_instance_p
;
ngap_gNB_instance_t
*
ngap_gNB_instance_p
;
struct
ngap_gNB_ue_context_s
*
ue_context_p
;
struct
ngap_gNB_ue_context_s
*
ue_context_p
;
NGAP_NGAP_PDU_t
pdu
;
NGAP_NGAP_PDU_t
pdu
;
NGAP_UECapabilityInfoIndication_t *out;
NGAP_UE
Radio
CapabilityInfoIndication_t
*
out
;
NGAP_UECapabilityInfoIndicationIEs_t *ie;
NGAP_UE
Radio
CapabilityInfoIndicationIEs_t
*
ie
;
uint8_t
*
buffer
;
uint8_t
*
buffer
;
uint32_t
length
;
uint32_t
length
;
/* Retrieve the NGAP gNB instance associated with Mod_id */
/* Retrieve the NGAP gNB instance associated with Mod_id */
...
@@ -882,7 +881,7 @@ int ngap_gNB_ue_capabilities(instance_t instance,
...
@@ -882,7 +881,7 @@ int ngap_gNB_ue_capabilities(instance_t instance,
return
-
1
;
return
-
1
;
}
}
/* UE capabilities message can occur either during an ngap connected state
/* UE
radio
capabilities message can occur either during an ngap connected state
* or during initial attach (for example: NAS authentication).
* or during initial attach (for example: NAS authentication).
*/
*/
if
(
!
(
ue_context_p
->
ue_state
==
NGAP_UE_CONNECTED
||
if
(
!
(
ue_context_p
->
ue_state
==
NGAP_UE_CONNECTED
||
...
@@ -896,37 +895,38 @@ int ngap_gNB_ue_capabilities(instance_t instance,
...
@@ -896,37 +895,38 @@ int ngap_gNB_ue_capabilities(instance_t instance,
/* Prepare the NGAP message to encode */
/* Prepare the NGAP message to encode */
memset
(
&
pdu
,
0
,
sizeof
(
pdu
));
memset
(
&
pdu
,
0
,
sizeof
(
pdu
));
pdu
.
present
=
NGAP_NGAP_PDU_PR_initiatingMessage
;
pdu
.
present
=
NGAP_NGAP_PDU_PR_initiatingMessage
;
pdu.choice.initiatingMessage.procedureCode = NGAP_ProcedureCode_id_UECapabilityInfoIndication;
pdu
.
choice
.
initiatingMessage
.
procedureCode
=
NGAP_ProcedureCode_id_UE
Radio
CapabilityInfoIndication
;
pdu
.
choice
.
initiatingMessage
.
criticality
=
NGAP_Criticality_ignore
;
pdu
.
choice
.
initiatingMessage
.
criticality
=
NGAP_Criticality_ignore
;
pdu.choice.initiatingMessage.value.present = NGAP_InitiatingMessage__value_PR_UECapabilityInfoIndication;
pdu
.
choice
.
initiatingMessage
.
value
.
present
=
NGAP_InitiatingMessage__value_PR_UE
Radio
CapabilityInfoIndication
;
out = &pdu.choice.initiatingMessage.value.choice.UECapabilityInfoIndication;
out
=
&
pdu
.
choice
.
initiatingMessage
.
value
.
choice
.
UE
Radio
CapabilityInfoIndication
;
/* mandatory */
/* mandatory */
ie = (NGAP_UE
CapabilityInfoIndicationIEs_t *)calloc(1, sizeof(NGAP_UE
CapabilityInfoIndicationIEs_t));
ie
=
(
NGAP_UE
RadioCapabilityInfoIndicationIEs_t
*
)
calloc
(
1
,
sizeof
(
NGAP_UERadio
CapabilityInfoIndicationIEs_t
));
ie
->
id
=
NGAP_ProtocolIE_ID_id_AMF_UE_NGAP_ID
;
ie
->
id
=
NGAP_ProtocolIE_ID_id_AMF_UE_NGAP_ID
;
ie
->
criticality
=
NGAP_Criticality_reject
;
ie
->
criticality
=
NGAP_Criticality_reject
;
ie->value.present = NGAP_UECapabilityInfoIndicationIEs__value_PR_AMF_UE_NGAP_ID;
ie
->
value
.
present
=
NGAP_UERadioCapabilityInfoIndicationIEs__value_PR_AMF_UE_NGAP_ID
;
ie->value.choice.AMF_UE_NGAP_ID = ue_context_p->amf_ue_ngap_id;
//ie->value.choice.AMF_UE_NGAP_ID = ue_context_p->amf_ue_ngap_id;
asn_uint642INTEGER
(
&
ie
->
value
.
choice
.
AMF_UE_NGAP_ID
,
ue_context_p
->
amf_ue_ngap_id
);
ASN_SEQUENCE_ADD
(
&
out
->
protocolIEs
.
list
,
ie
);
ASN_SEQUENCE_ADD
(
&
out
->
protocolIEs
.
list
,
ie
);
/* mandatory */
/* mandatory */
ie = (NGAP_UE
CapabilityInfoIndicationIEs_t *)calloc(1, sizeof(NGAP_UE
CapabilityInfoIndicationIEs_t));
ie
=
(
NGAP_UE
RadioCapabilityInfoIndicationIEs_t
*
)
calloc
(
1
,
sizeof
(
NGAP_UERadio
CapabilityInfoIndicationIEs_t
));
ie->id = NGAP_ProtocolIE_ID_id_
gNB
_UE_NGAP_ID;
ie
->
id
=
NGAP_ProtocolIE_ID_id_
RAN
_UE_NGAP_ID
;
ie
->
criticality
=
NGAP_Criticality_reject
;
ie
->
criticality
=
NGAP_Criticality_reject
;
ie->value.present = NGAP_UE
CapabilityInfoIndicationIEs__value_PR_GNB
_UE_NGAP_ID;
ie
->
value
.
present
=
NGAP_UE
RadioCapabilityInfoIndicationIEs__value_PR_RAN
_UE_NGAP_ID
;
ie->value.choice.
GNB
_UE_NGAP_ID = ue_cap_info_ind_p->gNB_ue_ngap_id;
ie
->
value
.
choice
.
RAN
_UE_NGAP_ID
=
ue_cap_info_ind_p
->
gNB_ue_ngap_id
;
ASN_SEQUENCE_ADD
(
&
out
->
protocolIEs
.
list
,
ie
);
ASN_SEQUENCE_ADD
(
&
out
->
protocolIEs
.
list
,
ie
);
/* mandatory */
/* mandatory */
ie = (NGAP_UE
CapabilityInfoIndicationIEs_t *)calloc(1, sizeof(NGAP_UE
CapabilityInfoIndicationIEs_t));
ie
=
(
NGAP_UE
RadioCapabilityInfoIndicationIEs_t
*
)
calloc
(
1
,
sizeof
(
NGAP_UERadio
CapabilityInfoIndicationIEs_t
));
ie
->
id
=
NGAP_ProtocolIE_ID_id_UERadioCapability
;
ie
->
id
=
NGAP_ProtocolIE_ID_id_UERadioCapability
;
ie
->
criticality
=
NGAP_Criticality_reject
;
ie
->
criticality
=
NGAP_Criticality_reject
;
ie->value.present = NGAP_UECapabilityInfoIndicationIEs__value_PR_UERadioCapability;
ie
->
value
.
present
=
NGAP_UE
Radio
CapabilityInfoIndicationIEs__value_PR_UERadioCapability
;
ie
->
value
.
choice
.
UERadioCapability
.
buf
=
ue_cap_info_ind_p
->
ue_radio_cap
.
buffer
;
ie
->
value
.
choice
.
UERadioCapability
.
buf
=
ue_cap_info_ind_p
->
ue_radio_cap
.
buffer
;
ie
->
value
.
choice
.
UERadioCapability
.
size
=
ue_cap_info_ind_p
->
ue_radio_cap
.
length
;
ie
->
value
.
choice
.
UERadioCapability
.
size
=
ue_cap_info_ind_p
->
ue_radio_cap
.
length
;
ASN_SEQUENCE_ADD
(
&
out
->
protocolIEs
.
list
,
ie
);
ASN_SEQUENCE_ADD
(
&
out
->
protocolIEs
.
list
,
ie
);
/* optional */
/* optional */
//NGAP_UERadioCapabilityForPaging TBD
if
(
ngap_gNB_encode_pdu
(
&
pdu
,
&
buffer
,
&
length
)
<
0
)
{
if
(
ngap_gNB_encode_pdu
(
&
pdu
,
&
buffer
,
&
length
)
<
0
)
{
/* Encode procedure has failed... */
/* Encode procedure has failed... */
NGAP_ERROR("Failed to encode UE capabilities indication\n");
NGAP_ERROR
(
"Failed to encode UE
radio
capabilities indication
\n
"
);
return
-
1
;
return
-
1
;
}
}
...
@@ -943,7 +943,6 @@ int ngap_gNB_ue_capabilities(instance_t instance,
...
@@ -943,7 +943,6 @@ int ngap_gNB_ue_capabilities(instance_t instance,
ngap_gNB_itti_send_sctp_data_req
(
ngap_gNB_instance_p
->
instance
,
ngap_gNB_itti_send_sctp_data_req
(
ngap_gNB_instance_p
->
instance
,
ue_context_p
->
amf_ref
->
assoc_id
,
buffer
,
ue_context_p
->
amf_ref
->
assoc_id
,
buffer
,
length
,
ue_context_p
->
tx_stream
);
length
,
ue_context_p
->
tx_stream
);
#endif
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