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
spbro
OpenXG-RAN
Commits
d906c3c9
Commit
d906c3c9
authored
Jun 02, 2023
by
Robert Schmidt
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/remove-duplications-of-srb-list' into integration_2023_w22
parents
3ff39449
313d34a8
Changes
11
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
184 additions
and
370 deletions
+184
-370
openair2/LAYER2/NR_MAC_UE/mac_proto.h
openair2/LAYER2/NR_MAC_UE/mac_proto.h
+0
-9
openair2/LAYER2/NR_MAC_UE/nr_ue_procedures.c
openair2/LAYER2/NR_MAC_UE/nr_ue_procedures.c
+8
-0
openair2/RRC/NR/MESSAGES/asn1_msg.c
openair2/RRC/NR/MESSAGES/asn1_msg.c
+51
-125
openair2/RRC/NR/MESSAGES/asn1_msg.h
openair2/RRC/NR/MESSAGES/asn1_msg.h
+16
-15
openair2/RRC/NR/cucp_cuup_direct.c
openair2/RRC/NR/cucp_cuup_direct.c
+5
-26
openair2/RRC/NR/nr_rrc_common.c
openair2/RRC/NR/nr_rrc_common.c
+0
-11
openair2/RRC/NR/nr_rrc_common.h
openair2/RRC/NR/nr_rrc_common.h
+4
-19
openair2/RRC/NR/nr_rrc_defs.h
openair2/RRC/NR/nr_rrc_defs.h
+1
-3
openair2/RRC/NR/rrc_gNB.c
openair2/RRC/NR/rrc_gNB.c
+96
-155
openair2/RRC/NR/rrc_gNB_NGAP.c
openair2/RRC/NR/rrc_gNB_NGAP.c
+1
-3
openair2/RRC/NR_UE/rrc_UE.c
openair2/RRC/NR_UE/rrc_UE.c
+2
-4
No files found.
openair2/LAYER2/NR_MAC_UE/mac_proto.h
View file @
d906c3c9
...
@@ -428,15 +428,6 @@ void build_ssb_to_ro_map(NR_UE_MAC_INST_t *mac);
...
@@ -428,15 +428,6 @@ void build_ssb_to_ro_map(NR_UE_MAC_INST_t *mac);
void
ue_init_config_request
(
NR_UE_MAC_INST_t
*
mac
,
int
scs
);
void
ue_init_config_request
(
NR_UE_MAC_INST_t
*
mac
,
int
scs
);
static
uint8_t
nr_extract_dci_info
(
NR_UE_MAC_INST_t
*
mac
,
nr_dci_format_t
dci_format
,
uint8_t
dci_size
,
uint16_t
rnti
,
int
ss_type
,
uint64_t
*
dci_pdu
,
dci_pdu_rel15_t
*
dci_pdu_rel15
,
int
slot
);
fapi_nr_ul_config_request_t
*
get_ul_config_request
(
NR_UE_MAC_INST_t
*
mac
,
int
slot
,
int
fb_time
);
fapi_nr_ul_config_request_t
*
get_ul_config_request
(
NR_UE_MAC_INST_t
*
mac
,
int
slot
,
int
fb_time
);
fapi_nr_dl_config_request_t
*
get_dl_config_request
(
NR_UE_MAC_INST_t
*
mac
,
int
slot
);
fapi_nr_dl_config_request_t
*
get_dl_config_request
(
NR_UE_MAC_INST_t
*
mac
,
int
slot
);
...
...
openair2/LAYER2/NR_MAC_UE/nr_ue_procedures.c
View file @
d906c3c9
...
@@ -149,6 +149,14 @@ const initial_pucch_resource_t initial_pucch_resource[16] = {
...
@@ -149,6 +149,14 @@ const initial_pucch_resource_t initial_pucch_resource[16] = {
/* 14 */
{
1
,
0
,
14
,
4
,
4
,
{
0
,
3
,
6
,
9
}
},
/* 14 */
{
1
,
0
,
14
,
4
,
4
,
{
0
,
3
,
6
,
9
}
},
/* 15 */
{
1
,
0
,
14
,
0
,
4
,
{
0
,
3
,
6
,
9
}
},
/* 15 */
{
1
,
0
,
14
,
0
,
4
,
{
0
,
3
,
6
,
9
}
},
};
};
static
uint8_t
nr_extract_dci_info
(
NR_UE_MAC_INST_t
*
mac
,
nr_dci_format_t
dci_format
,
uint8_t
dci_size
,
uint16_t
rnti
,
int
ss_type
,
uint64_t
*
dci_pdu
,
dci_pdu_rel15_t
*
dci_pdu_rel15
,
int
slot
);
void
nr_ue_init_mac
(
module_id_t
module_idP
)
void
nr_ue_init_mac
(
module_id_t
module_idP
)
{
{
...
...
openair2/RRC/NR/MESSAGES/asn1_msg.c
View file @
d906c3c9
...
@@ -511,51 +511,25 @@ int do_RRCSetup(rrc_gNB_ue_context_t *const ue_context_pP,
...
@@ -511,51 +511,25 @@ int do_RRCSetup(rrc_gNB_ue_context_t *const ue_context_pP,
const
uint8_t
transaction_id
,
const
uint8_t
transaction_id
,
const
uint8_t
*
masterCellGroup
,
const
uint8_t
*
masterCellGroup
,
int
masterCellGroup_len
,
int
masterCellGroup_len
,
const
gNB_RrcConfigurationReq
*
configuration
)
const
gNB_RrcConfigurationReq
*
configuration
,
NR_SRB_ToAddModList_t
*
SRBs
)
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
{
{
asn_enc_rval_t
enc_rval
;
AssertFatal
(
ue_context_pP
!=
NULL
,
"ue_context_p is null
\n
"
);
NR_DL_CCCH_Message_t
dl_ccch_msg
;
NR_RRCSetup_t
*
rrcSetup
;
NR_RRCSetup_IEs_t
*
ie
;
NR_SRB_ToAddMod_t
*
SRB1_config
=
NULL
;
NR_PDCP_Config_t
*
pdcp_Config
=
NULL
;
AssertFatal
(
ue_context_pP
!=
NULL
,
"ue_context_p is null
\n
"
);
gNB_RRC_UE_t
*
ue_p
=
&
ue_context_pP
->
ue_context
;
gNB_RRC_UE_t
*
ue_p
=
&
ue_context_pP
->
ue_context
;
NR_SRB_ToAddModList_t
**
SRB_configList
=
&
ue_p
->
SRB_configList
;
NR_DL_CCCH_Message_t
dl_ccch_msg
=
{
0
};
memset
((
void
*
)
&
dl_ccch_msg
,
0
,
sizeof
(
NR_DL_CCCH_Message_t
));
dl_ccch_msg
.
message
.
present
=
NR_DL_CCCH_MessageType_PR_c1
;
dl_ccch_msg
.
message
.
present
=
NR_DL_CCCH_MessageType_PR_c1
;
dl_ccch_msg
.
message
.
choice
.
c1
=
CALLOC
(
1
,
sizeof
(
struct
NR_DL_CCCH_MessageType__c1
));
asn1cCalloc
(
dl_ccch_msg
.
message
.
choice
.
c1
,
dl_msg
);
dl_ccch_msg
.
message
.
choice
.
c1
->
present
=
NR_DL_CCCH_MessageType__c1_PR_rrcSetup
;
dl_msg
->
present
=
NR_DL_CCCH_MessageType__c1_PR_rrcSetup
;
dl_ccch_msg
.
message
.
choice
.
c1
->
choice
.
rrcSetup
=
calloc
(
1
,
sizeof
(
NR_RRCSetup_t
));
asn1cCalloc
(
dl_msg
->
choice
.
rrcSetup
,
rrcSetup
);
rrcSetup
=
dl_ccch_msg
.
message
.
choice
.
c1
->
choice
.
rrcSetup
;
rrcSetup
->
criticalExtensions
.
present
=
NR_RRCSetup__criticalExtensions_PR_rrcSetup
;
rrcSetup
->
criticalExtensions
.
present
=
NR_RRCSetup__criticalExtensions_PR_rrcSetup
;
rrcSetup
->
rrc_TransactionIdentifier
=
transaction_id
;
rrcSetup
->
rrc_TransactionIdentifier
=
transaction_id
;
rrcSetup
->
criticalExtensions
.
choice
.
rrcSetup
=
calloc
(
1
,
sizeof
(
NR_RRCSetup_IEs_t
));
rrcSetup
->
criticalExtensions
.
choice
.
rrcSetup
=
calloc
(
1
,
sizeof
(
NR_RRCSetup_IEs_t
));
ie
=
rrcSetup
->
criticalExtensions
.
choice
.
rrcSetup
;
NR_RRCSetup_IEs_t
*
ie
=
rrcSetup
->
criticalExtensions
.
choice
.
rrcSetup
;
/****************************** radioBearerConfig ******************************/
/****************************** radioBearerConfig ******************************/
ie
->
radioBearerConfig
.
srb_ToAddModList
=
SRBs
;
/* Configure SRB1 */
if
(
*
SRB_configList
)
{
free
(
*
SRB_configList
);
}
*
SRB_configList
=
calloc
(
1
,
sizeof
(
NR_SRB_ToAddModList_t
));
// SRB1
/* TODO */
SRB1_config
=
calloc
(
1
,
sizeof
(
NR_SRB_ToAddMod_t
));
SRB1_config
->
srb_Identity
=
1
;
// pdcp_Config->t_Reordering
SRB1_config
->
pdcp_Config
=
pdcp_Config
;
ie
->
radioBearerConfig
.
srb_ToAddModList
=
*
SRB_configList
;
asn1cSeqAdd
(
&
(
*
SRB_configList
)
->
list
,
SRB1_config
);
ie
->
radioBearerConfig
.
srb3_ToRelease
=
NULL
;
ie
->
radioBearerConfig
.
srb3_ToRelease
=
NULL
;
ie
->
radioBearerConfig
.
drb_ToAddModList
=
NULL
;
ie
->
radioBearerConfig
.
drb_ToAddModList
=
NULL
;
ie
->
radioBearerConfig
.
drb_ToReleaseList
=
NULL
;
ie
->
radioBearerConfig
.
drb_ToReleaseList
=
NULL
;
...
@@ -571,24 +545,17 @@ int do_RRCSetup(rrc_gNB_ue_context_t *const ue_context_pP,
...
@@ -571,24 +545,17 @@ int do_RRCSetup(rrc_gNB_ue_context_t *const ue_context_pP,
// decode masterCellGroup OCTET_STRING received from DU and place in ue context
// decode masterCellGroup OCTET_STRING received from DU and place in ue context
ue_p
->
masterCellGroup
=
decode_cellGroupConfig
(
masterCellGroup
,
masterCellGroup_len
);
ue_p
->
masterCellGroup
=
decode_cellGroupConfig
(
masterCellGroup
,
masterCellGroup_len
);
if
(
LOG_DEBUGFLAG
(
DEBUG_ASN1
)
)
{
if
(
LOG_DEBUGFLAG
(
DEBUG_ASN1
)
)
{
xer_fprint
(
stdout
,
&
asn_DEF_NR_CellGroupConfig
,
ue_p
->
masterCellGroup
);
xer_fprint
(
stdout
,
&
asn_DEF_NR_CellGroupConfig
,
ue_p
->
masterCellGroup
);
xer_fprint
(
stdout
,
&
asn_DEF_NR_DL_CCCH_Message
,
(
void
*
)
&
dl_ccch_msg
);
xer_fprint
(
stdout
,
&
asn_DEF_NR_DL_CCCH_Message
,
(
void
*
)
&
dl_ccch_msg
);
}
}
enc_rval
=
uper_encode_to_buffer
(
&
asn_DEF_NR_DL_CCCH_Message
,
asn_enc_rval_t
enc_rval
=
uper_encode_to_buffer
(
&
asn_DEF_NR_DL_CCCH_Message
,
NULL
,
(
void
*
)
&
dl_ccch_msg
,
buffer
,
1000
);
NULL
,
(
void
*
)
&
dl_ccch_msg
,
buffer
,
1000
);
AssertFatal
(
enc_rval
.
encoded
>
0
,
"ASN1 message encoding failed (%s, %lu)!
\n
"
,
AssertFatal
(
enc_rval
.
encoded
>
0
,
"ASN1 message encoding failed (%s, %lu)!
\n
"
,
enc_rval
.
failed_type
->
name
,
enc_rval
.
encoded
);
enc_rval
.
failed_type
->
name
,
enc_rval
.
encoded
);
LOG_D
(
NR_RRC
,
"RRCSetup Encoded %zd bits (%zd bytes)
\n
"
,
LOG_D
(
NR_RRC
,
"RRCSetup Encoded %zd bits (%zd bytes)
\n
"
,
enc_rval
.
encoded
,
(
enc_rval
.
encoded
+
7
)
/
8
);
enc_rval
.
encoded
,(
enc_rval
.
encoded
+
7
)
/
8
);
return
((
enc_rval
.
encoded
+
7
)
/
8
);
return
((
enc_rval
.
encoded
+
7
)
/
8
);
}
}
uint8_t
do_NR_SecurityModeCommand
(
uint8_t
do_NR_SecurityModeCommand
(
...
@@ -1139,62 +1106,21 @@ int do_RRCReestablishment(const protocol_ctxt_t *const ctxt_pP,
...
@@ -1139,62 +1106,21 @@ int do_RRCReestablishment(const protocol_ctxt_t *const ctxt_pP,
uint8_t
*
const
buffer
,
uint8_t
*
const
buffer
,
size_t
buffer_size
,
size_t
buffer_size
,
const
uint8_t
Transaction_id
,
const
uint8_t
Transaction_id
,
NR_SRB_ToAddModList_t
*
*
SRB_configList
,
NR_SRB_ToAddModList_t
*
SRB_configList
,
const
uint8_t
*
masterCellGroup_from_DU
,
const
uint8_t
*
masterCellGroup_from_DU
,
NR_ServingCellConfigCommon_t
*
scc
,
NR_ServingCellConfigCommon_t
*
scc
,
rrc_gNB_carrier_data_t
*
carrier
)
rrc_gNB_carrier_data_t
*
carrier
)
{
{
asn_enc_rval_t
enc_rval
;
asn_enc_rval_t
enc_rval
;
struct
NR_SRB_ToAddMod
*
SRB1_config
=
NULL
;
struct
NR_SRB_ToAddMod
*
SRB2_config
=
NULL
;
NR_DL_DCCH_Message_t
dl_dcch_msg
=
{
0
};
NR_DL_DCCH_Message_t
dl_dcch_msg
=
{
0
};
NR_RRCReestablishment_t
*
rrcReestablishment
=
NULL
;
NR_RRCReestablishment_t
*
rrcReestablishment
=
NULL
;
NR_SRB_ToAddModList_t
**
SRB_configList2
=
NULL
;
SRB_configList2
=
&
ue_context_pP
->
ue_context
.
SRB_configList2
[
Transaction_id
];
if
(
*
SRB_configList2
)
{
free
(
*
SRB_configList2
);
}
*
SRB_configList2
=
CALLOC
(
1
,
sizeof
(
NR_SRB_ToAddModList_t
));
dl_dcch_msg
.
message
.
present
=
NR_DL_DCCH_MessageType_PR_c1
;
dl_dcch_msg
.
message
.
present
=
NR_DL_DCCH_MessageType_PR_c1
;
dl_dcch_msg
.
message
.
choice
.
c1
=
calloc
(
1
,
sizeof
(
struct
NR_DL_DCCH_MessageType__c1
));
dl_dcch_msg
.
message
.
choice
.
c1
=
calloc
(
1
,
sizeof
(
struct
NR_DL_DCCH_MessageType__c1
));
dl_dcch_msg
.
message
.
choice
.
c1
->
present
=
NR_DL_DCCH_MessageType__c1_PR_rrcReestablishment
;
dl_dcch_msg
.
message
.
choice
.
c1
->
present
=
NR_DL_DCCH_MessageType__c1_PR_rrcReestablishment
;
dl_dcch_msg
.
message
.
choice
.
c1
->
choice
.
rrcReestablishment
=
CALLOC
(
1
,
sizeof
(
NR_RRCReestablishment_t
));
dl_dcch_msg
.
message
.
choice
.
c1
->
choice
.
rrcReestablishment
=
CALLOC
(
1
,
sizeof
(
NR_RRCReestablishment_t
));
rrcReestablishment
=
dl_dcch_msg
.
message
.
choice
.
c1
->
choice
.
rrcReestablishment
;
rrcReestablishment
=
dl_dcch_msg
.
message
.
choice
.
c1
->
choice
.
rrcReestablishment
;
// get old configuration of SRB2
if
(
*
SRB_configList
!=
NULL
)
{
for
(
int
i
=
0
;
(
i
<
(
*
SRB_configList
)
->
list
.
count
)
&&
(
i
<
3
);
i
++
)
{
LOG_D
(
NR_RRC
,
"(*SRB_configList)->list.array[%d]->srb_Identity=%ld
\n
"
,
i
,
(
*
SRB_configList
)
->
list
.
array
[
i
]
->
srb_Identity
);
if
((
*
SRB_configList
)
->
list
.
array
[
i
]
->
srb_Identity
==
2
)
{
SRB2_config
=
(
*
SRB_configList
)
->
list
.
array
[
i
];
}
else
if
((
*
SRB_configList
)
->
list
.
array
[
i
]
->
srb_Identity
==
1
)
{
SRB1_config
=
(
*
SRB_configList
)
->
list
.
array
[
i
];
}
}
}
if
(
SRB1_config
==
NULL
)
{
// default SRB1 configuration
LOG_W
(
NR_RRC
,
"SRB1 configuration does not exist in SRB configuration list, use default
\n
"
);
/// SRB1
SRB1_config
=
CALLOC
(
1
,
sizeof
(
*
SRB1_config
));
SRB1_config
->
srb_Identity
=
1
;
}
if
(
SRB2_config
==
NULL
)
{
LOG_W
(
NR_RRC
,
"SRB2 configuration does not exist in SRB configuration list
\n
"
);
}
else
{
asn1cSeqAdd
(
&
(
*
SRB_configList2
)
->
list
,
SRB2_config
);
}
if
(
*
SRB_configList
)
{
free
(
*
SRB_configList
);
}
*
SRB_configList
=
CALLOC
(
1
,
sizeof
(
NR_SRB_ToAddModList_t
));
asn1cSeqAdd
(
&
(
*
SRB_configList
)
->
list
,
SRB1_config
);
/****************************** masterCellGroup ******************************/
/****************************** masterCellGroup ******************************/
rrcReestablishment
->
rrc_TransactionIdentifier
=
Transaction_id
;
rrcReestablishment
->
rrc_TransactionIdentifier
=
Transaction_id
;
rrcReestablishment
->
criticalExtensions
.
present
=
NR_RRCReestablishment__criticalExtensions_PR_rrcReestablishment
;
rrcReestablishment
->
criticalExtensions
.
present
=
NR_RRCReestablishment__criticalExtensions_PR_rrcReestablishment
;
...
...
openair2/RRC/NR/MESSAGES/asn1_msg.h
View file @
d906c3c9
...
@@ -104,7 +104,8 @@ int do_RRCSetup(rrc_gNB_ue_context_t *const ue_context_pP,
...
@@ -104,7 +104,8 @@ int do_RRCSetup(rrc_gNB_ue_context_t *const ue_context_pP,
const
uint8_t
transaction_id
,
const
uint8_t
transaction_id
,
const
uint8_t
*
masterCellGroup
,
const
uint8_t
*
masterCellGroup
,
int
masterCellGroup_len
,
int
masterCellGroup_len
,
const
gNB_RrcConfigurationReq
*
configuration
);
const
gNB_RrcConfigurationReq
*
configuration
,
NR_SRB_ToAddModList_t
*
SRBs
);
uint8_t
do_NR_SecurityModeCommand
(
uint8_t
do_NR_SecurityModeCommand
(
const
protocol_ctxt_t
*
const
ctxt_pP
,
const
protocol_ctxt_t
*
const
ctxt_pP
,
...
@@ -177,7 +178,7 @@ int do_RRCReestablishment(const protocol_ctxt_t *const ctxt_pP,
...
@@ -177,7 +178,7 @@ int do_RRCReestablishment(const protocol_ctxt_t *const ctxt_pP,
uint8_t
*
const
buffer
,
uint8_t
*
const
buffer
,
size_t
buffer_size
,
size_t
buffer_size
,
const
uint8_t
Transaction_id
,
const
uint8_t
Transaction_id
,
NR_SRB_ToAddModList_t
*
*
SRB_configList
,
NR_SRB_ToAddModList_t
*
SRB_configList
,
const
uint8_t
*
masterCellGroup_from_DU
,
const
uint8_t
*
masterCellGroup_from_DU
,
NR_ServingCellConfigCommon_t
*
scc
,
NR_ServingCellConfigCommon_t
*
scc
,
rrc_gNB_carrier_data_t
*
carrier
);
rrc_gNB_carrier_data_t
*
carrier
);
...
...
openair2/RRC/NR/cucp_cuup_direct.c
View file @
d906c3c9
...
@@ -104,9 +104,8 @@ static int drb_config_gtpu_create(const protocol_ctxt_t *const ctxt_p,
...
@@ -104,9 +104,8 @@ static int drb_config_gtpu_create(const protocol_ctxt_t *const ctxt_p,
rrc_gNB_ue_context_t
*
ue_context_p
,
rrc_gNB_ue_context_t
*
ue_context_p
,
e1ap_bearer_setup_req_t
*
const
req
,
e1ap_bearer_setup_req_t
*
const
req
,
NR_DRB_ToAddModList_t
*
DRB_configList
,
NR_DRB_ToAddModList_t
*
DRB_configList
,
NR_SRB_ToAddModList_t
*
SRB_configList
,
instance_t
instance
)
instance_t
instance
)
{
{
gtpv1u_gnb_create_tunnel_req_t
create_tunnel_req
=
{
0
};
gtpv1u_gnb_create_tunnel_req_t
create_tunnel_req
=
{
0
};
gtpv1u_gnb_create_tunnel_resp_t
create_tunnel_resp
=
{
0
};
gtpv1u_gnb_create_tunnel_resp_t
create_tunnel_resp
=
{
0
};
gNB_RRC_UE_t
*
UE
=
&
ue_context_p
->
ue_context
;
gNB_RRC_UE_t
*
UE
=
&
ue_context_p
->
ue_context
;
...
@@ -151,10 +150,7 @@ static int drb_config_gtpu_create(const protocol_ctxt_t *const ctxt_p,
...
@@ -151,10 +150,7 @@ static int drb_config_gtpu_create(const protocol_ctxt_t *const ctxt_p,
/* Refresh SRBs/DRBs */
/* Refresh SRBs/DRBs */
LOG_D
(
NR_RRC
,
"Configuring PDCP DRBs/SRBs for UE %x
\n
"
,
UE
->
rnti
);
LOG_D
(
NR_RRC
,
"Configuring PDCP DRBs for UE %x
\n
"
,
UE
->
rnti
);
nr_pdcp_add_srbs
(
ctxt_p
->
enb_flag
,
ctxt_p
->
rntiMaybeUEid
,
SRB_configList
,
(
UE
->
integrity_algorithm
<<
4
)
|
UE
->
ciphering_algorithm
,
kRRCenc
,
kRRCint
);
nr_pdcp_add_drbs
(
ctxt_p
->
enb_flag
,
nr_pdcp_add_drbs
(
ctxt_p
->
enb_flag
,
ctxt_p
->
rntiMaybeUEid
,
ctxt_p
->
rntiMaybeUEid
,
0
,
0
,
...
@@ -167,21 +163,6 @@ static int drb_config_gtpu_create(const protocol_ctxt_t *const ctxt_p,
...
@@ -167,21 +163,6 @@ static int drb_config_gtpu_create(const protocol_ctxt_t *const ctxt_p,
return
ret
;
return
ret
;
}
}
static
NR_SRB_ToAddModList_t
**
generateSRB2_confList
(
gNB_RRC_UE_t
*
ue
,
NR_SRB_ToAddModList_t
*
SRB_configList
,
uint8_t
xid
)
{
NR_SRB_ToAddModList_t
**
SRB_configList2
=
NULL
;
SRB_configList2
=
&
ue
->
SRB_configList2
[
xid
];
if
(
*
SRB_configList2
==
NULL
)
{
*
SRB_configList2
=
CALLOC
(
1
,
sizeof
(
**
SRB_configList2
));
NR_SRB_ToAddMod_t
*
SRB2_config
=
CALLOC
(
1
,
sizeof
(
*
SRB2_config
));
SRB2_config
->
srb_Identity
=
2
;
asn1cSeqAdd
(
&
(
*
SRB_configList2
)
->
list
,
SRB2_config
);
asn1cSeqAdd
(
&
SRB_configList
->
list
,
SRB2_config
);
}
return
SRB_configList2
;
}
static
void
cucp_cuup_bearer_context_setup_direct
(
e1ap_bearer_setup_req_t
*
const
req
,
instance_t
instance
,
uint8_t
xid
)
static
void
cucp_cuup_bearer_context_setup_direct
(
e1ap_bearer_setup_req_t
*
const
req
,
instance_t
instance
,
uint8_t
xid
)
{
{
rrc_gNB_ue_context_t
*
ue_context_p
=
rrc_gNB_get_ue_context_by_rnti
(
RC
.
nrrrc
[
instance
],
req
->
rnti
);
rrc_gNB_ue_context_t
*
ue_context_p
=
rrc_gNB_get_ue_context_by_rnti
(
RC
.
nrrrc
[
instance
],
req
->
rnti
);
...
@@ -205,10 +186,8 @@ static void cucp_cuup_bearer_context_setup_direct(e1ap_bearer_setup_req_t *const
...
@@ -205,10 +186,8 @@ static void cucp_cuup_bearer_context_setup_direct(e1ap_bearer_setup_req_t *const
}
}
gNB_RRC_INST
*
rrc
=
RC
.
nrrrc
[
ctxt
.
module_id
];
gNB_RRC_INST
*
rrc
=
RC
.
nrrrc
[
ctxt
.
module_id
];
// Fixme: xid not random, but almost!
NR_SRB_ToAddModList_t
**
SRB_configList2
=
generateSRB2_confList
(
UE
,
UE
->
SRB_configList
,
UE
->
pduSession
[
0
].
xid
);
// GTP tunnel for UL
// GTP tunnel for UL
int
ret
=
drb_config_gtpu_create
(
&
ctxt
,
ue_context_p
,
req
,
UE
->
DRB_configList
,
*
SRB_configList2
,
rrc
->
e1_inst
);
int
ret
=
drb_config_gtpu_create
(
&
ctxt
,
ue_context_p
,
req
,
UE
->
DRB_configList
,
rrc
->
e1_inst
);
if
(
ret
<
0
)
AssertFatal
(
false
,
"Unable to configure DRB or to create GTP Tunnel
\n
"
);
if
(
ret
<
0
)
AssertFatal
(
false
,
"Unable to configure DRB or to create GTP Tunnel
\n
"
);
// Used to store teids: if monolithic, will simply be NULL
// Used to store teids: if monolithic, will simply be NULL
...
...
openair2/RRC/NR/nr_rrc_common.c
View file @
d906c3c9
...
@@ -54,14 +54,3 @@ void rrc_init_nr_srb_param(NR_LCHAN_DESC *chan)
...
@@ -54,14 +54,3 @@ void rrc_init_nr_srb_param(NR_LCHAN_DESC *chan)
chan
->
Delay_class
=
1
;
chan
->
Delay_class
=
1
;
return
;
return
;
}
}
//-----------------------------------------------------------------------------
void
rrc_config_nr_buffer
(
NR_SRB_INFO
*
Srb_info
,
uint8_t
Lchan_type
,
uint8_t
Role
)
{
Srb_info
->
Rx_buffer
.
payload_size
=
0
;
Srb_info
->
Tx_buffer
.
payload_size
=
0
;
}
//-----------------------------------------------------------------------------
openair2/RRC/NR/nr_rrc_common.h
View file @
d906c3c9
...
@@ -61,31 +61,16 @@ typedef struct RB_INFO_NR_s {
...
@@ -61,31 +61,16 @@ typedef struct RB_INFO_NR_s {
}
NR_RB_INFO
;
}
NR_RB_INFO
;
typedef
struct
NR_SRB_INFO_s
{
typedef
struct
NR_SRB_INFO_s
{
uint16_t
Srb_id
;
//=Lchan_id
NR_RRC_BUFFER
Rx_buffer
;
NR_RRC_BUFFER
Rx_buffer
;
NR_RRC_BUFFER
Tx_buffer
;
NR_RRC_BUFFER
Tx_buffer
;
NR_LCHAN_DESC
Lchan_desc
[
2
];
unsigned
int
Trans_id
;
uint8_t
Active
;
}
NR_SRB_INFO
;
}
NR_SRB_INFO
;
typedef
struct
RB_INFO_TABLE_ENTRY_NR_s
{
NR_RB_INFO
Rb_info
;
uint8_t
Active
;
uint32_t
Next_check_frame
;
uint8_t
status
;
}
NR_RB_INFO_TABLE_ENTRY
;
typedef
struct
SRB_INFO_TABLE_ENTRY_NR_s
{
typedef
struct
SRB_INFO_TABLE_ENTRY_NR_s
{
NR_SRB_INFO
Srb_info
;
NR_SRB_INFO
Srb_info
;
uint8_t
Active
;
uint8_t
Active
;
uint8_t
status
;
uint8_t
status
;
uint32_t
Next_check_frame
;
}
NR_SRB_INFO_TABLE_ENTRY
;
}
NR_SRB_INFO_TABLE_ENTRY
;
void
rrc_init_nr_srb_param
(
NR_LCHAN_DESC
*
chan
);
void
rrc_init_nr_srb_param
(
NR_LCHAN_DESC
*
chan
);
void
rrc_config_nr_buffer
(
NR_SRB_INFO
*
Srb_info
,
uint8_t
Lchan_type
,
uint8_t
Role
);
#endif
#endif
openair2/RRC/NR/nr_rrc_defs.h
View file @
d906c3c9
...
@@ -237,8 +237,6 @@ typedef enum {
...
@@ -237,8 +237,6 @@ typedef enum {
typedef
struct
gNB_RRC_UE_s
{
typedef
struct
gNB_RRC_UE_s
{
uint8_t
primaryCC_id
;
uint8_t
primaryCC_id
;
NR_SRB_ToAddModList_t
*
SRB_configList
;
NR_SRB_ToAddModList_t
*
SRB_configList2
[
NR_RRC_TRANSACTION_IDENTIFIER_NUMBER
];
NR_DRB_ToAddModList_t
*
DRB_configList
;
NR_DRB_ToAddModList_t
*
DRB_configList
;
NR_DRB_ToAddModList_t
*
DRB_configList2
[
NR_RRC_TRANSACTION_IDENTIFIER_NUMBER
];
NR_DRB_ToAddModList_t
*
DRB_configList2
[
NR_RRC_TRANSACTION_IDENTIFIER_NUMBER
];
NR_DRB_ToReleaseList_t
*
DRB_Release_configList2
[
NR_RRC_TRANSACTION_IDENTIFIER_NUMBER
];
NR_DRB_ToReleaseList_t
*
DRB_Release_configList2
[
NR_RRC_TRANSACTION_IDENTIFIER_NUMBER
];
...
...
openair2/RRC/NR/rrc_gNB.c
View file @
d906c3c9
This diff is collapsed.
Click to expand it.
openair2/RRC/NR/rrc_gNB_NGAP.c
View file @
d906c3c9
...
@@ -128,8 +128,6 @@ nr_rrc_pdcp_config_security(
...
@@ -128,8 +128,6 @@ nr_rrc_pdcp_config_security(
)
)
//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
{
{
NR_SRB_ToAddModList_t
*
SRB_configList
=
ue_context_pP
->
ue_context
.
SRB_configList
;
(
void
)
SRB_configList
;
uint8_t
kRRCenc
[
16
]
=
{
0
};
uint8_t
kRRCenc
[
16
]
=
{
0
};
uint8_t
kRRCint
[
16
]
=
{
0
};
uint8_t
kRRCint
[
16
]
=
{
0
};
uint8_t
kUPenc
[
16
]
=
{
0
};
uint8_t
kUPenc
[
16
]
=
{
0
};
...
@@ -783,7 +781,7 @@ void rrc_gNB_process_NGAP_PDUSESSION_SETUP_REQ(MessageDef *msg_p, instance_t ins
...
@@ -783,7 +781,7 @@ void rrc_gNB_process_NGAP_PDUSESSION_SETUP_REQ(MessageDef *msg_p, instance_t ins
for
(
int
j
=
0
;
j
<
pdu
->
numDRB2Setup
;
j
++
)
{
for
(
int
j
=
0
;
j
<
pdu
->
numDRB2Setup
;
j
++
)
{
DRB_nGRAN_to_setup_t
*
drb
=
pdu
->
DRBnGRanList
+
j
;
DRB_nGRAN_to_setup_t
*
drb
=
pdu
->
DRBnGRanList
+
j
;
drb
->
id
=
i
+
j
+
1
;
drb
->
id
=
i
+
j
+
UE
->
nb_of_pdusessions
;
drb
->
defaultDRB
=
E1AP_DefaultDRB_true
;
drb
->
defaultDRB
=
E1AP_DefaultDRB_true
;
...
...
openair2/RRC/NR_UE/rrc_UE.c
View file @
d906c3c9
...
@@ -1653,8 +1653,7 @@ nr_rrc_ue_establish_srb1(
...
@@ -1653,8 +1653,7 @@ nr_rrc_ue_establish_srb1(
{
{
// add descriptor from RRC PDU
// add descriptor from RRC PDU
NR_UE_rrc_inst
[
ue_mod_idP
].
Srb1
[
gNB_index
].
Active
=
1
;
NR_UE_rrc_inst
[
ue_mod_idP
].
Srb1
[
gNB_index
].
Active
=
1
;
NR_UE_rrc_inst
[
ue_mod_idP
].
Srb1
[
gNB_index
].
status
=
RADIO_CONFIG_OK
;
//RADIO CFG
NR_UE_rrc_inst
[
ue_mod_idP
].
Srb1
[
gNB_index
].
status
=
RADIO_CONFIG_OK
;
// RADIO CFG
NR_UE_rrc_inst
[
ue_mod_idP
].
Srb1
[
gNB_index
].
Srb_info
.
Srb_id
=
1
;
LOG_I
(
NR_RRC
,
"[UE %d], CONFIG_SRB1 %d corresponding to gNB_index %d
\n
"
,
ue_mod_idP
,
DCCH
,
gNB_index
);
LOG_I
(
NR_RRC
,
"[UE %d], CONFIG_SRB1 %d corresponding to gNB_index %d
\n
"
,
ue_mod_idP
,
DCCH
,
gNB_index
);
return
(
0
);
return
(
0
);
}
}
...
@@ -1671,8 +1670,7 @@ nr_rrc_ue_establish_srb2(
...
@@ -1671,8 +1670,7 @@ nr_rrc_ue_establish_srb2(
{
{
// add descriptor from RRC PDU
// add descriptor from RRC PDU
NR_UE_rrc_inst
[
ue_mod_idP
].
Srb2
[
gNB_index
].
Active
=
1
;
NR_UE_rrc_inst
[
ue_mod_idP
].
Srb2
[
gNB_index
].
Active
=
1
;
NR_UE_rrc_inst
[
ue_mod_idP
].
Srb2
[
gNB_index
].
status
=
RADIO_CONFIG_OK
;
//RADIO CFG
NR_UE_rrc_inst
[
ue_mod_idP
].
Srb2
[
gNB_index
].
status
=
RADIO_CONFIG_OK
;
// RADIO CFG
NR_UE_rrc_inst
[
ue_mod_idP
].
Srb2
[
gNB_index
].
Srb_info
.
Srb_id
=
2
;
LOG_I
(
NR_RRC
,
"[UE %d], CONFIG_SRB2 %d corresponding to gNB_index %d
\n
"
,
ue_mod_idP
,
DCCH1
,
gNB_index
);
LOG_I
(
NR_RRC
,
"[UE %d], CONFIG_SRB2 %d corresponding to gNB_index %d
\n
"
,
ue_mod_idP
,
DCCH1
,
gNB_index
);
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