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
littleBu
OpenXG-RAN
Commits
124f4ab9
Commit
124f4ab9
authored
Jan 20, 2025
by
Guido Casati
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Improvements to rrc_gNB_process_e1_setup_req
* add const atttribute to input message * use malloc_or_fail
parent
5ea432c0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
6 deletions
+5
-6
openair2/RRC/NR/nr_rrc_proto.h
openair2/RRC/NR/nr_rrc_proto.h
+1
-1
openair2/RRC/NR/rrc_gNB_cuup.c
openair2/RRC/NR/rrc_gNB_cuup.c
+4
-5
No files found.
openair2/RRC/NR/nr_rrc_proto.h
View file @
124f4ab9
...
@@ -85,7 +85,7 @@ void rrc_gNB_generate_dedicatedRRCReconfiguration_release(gNB_RRC_INST *rrc,
...
@@ -85,7 +85,7 @@ void rrc_gNB_generate_dedicatedRRCReconfiguration_release(gNB_RRC_INST *rrc,
bool
ue_associated_to_cuup
(
const
gNB_RRC_INST
*
rrc
,
const
gNB_RRC_UE_t
*
ue
);
bool
ue_associated_to_cuup
(
const
gNB_RRC_INST
*
rrc
,
const
gNB_RRC_UE_t
*
ue
);
sctp_assoc_t
get_existing_cuup_for_ue
(
const
gNB_RRC_INST
*
rrc
,
const
gNB_RRC_UE_t
*
ue
);
sctp_assoc_t
get_existing_cuup_for_ue
(
const
gNB_RRC_INST
*
rrc
,
const
gNB_RRC_UE_t
*
ue
);
sctp_assoc_t
get_new_cuup_for_ue
(
const
gNB_RRC_INST
*
rrc
,
const
gNB_RRC_UE_t
*
ue
,
int
sst
,
int
sd
);
sctp_assoc_t
get_new_cuup_for_ue
(
const
gNB_RRC_INST
*
rrc
,
const
gNB_RRC_UE_t
*
ue
,
int
sst
,
int
sd
);
int
rrc_gNB_process_e1_setup_req
(
sctp_assoc_t
assoc_id
,
e1ap_setup_req_t
*
req
);
int
rrc_gNB_process_e1_setup_req
(
sctp_assoc_t
assoc_id
,
const
e1ap_setup_req_t
*
req
);
/* Process indication of E1 connection loss on CU-CP */
/* Process indication of E1 connection loss on CU-CP */
void
rrc_gNB_process_e1_lost_connection
(
gNB_RRC_INST
*
rrc
,
e1ap_lost_connection_t
*
lc
,
sctp_assoc_t
assoc_id
);
void
rrc_gNB_process_e1_lost_connection
(
gNB_RRC_INST
*
rrc
,
e1ap_lost_connection_t
*
lc
,
sctp_assoc_t
assoc_id
);
...
...
openair2/RRC/NR/rrc_gNB_cuup.c
View file @
124f4ab9
...
@@ -161,7 +161,7 @@ static void e1ap_setup_failure(sctp_assoc_t assoc_id, uint64_t transac_id, e1ap_
...
@@ -161,7 +161,7 @@ static void e1ap_setup_failure(sctp_assoc_t assoc_id, uint64_t transac_id, e1ap_
/**
/**
* @brief E1AP Setup Request processing on CU-CP
* @brief E1AP Setup Request processing on CU-CP
*/
*/
int
rrc_gNB_process_e1_setup_req
(
sctp_assoc_t
assoc_id
,
e1ap_setup_req_t
*
req
)
int
rrc_gNB_process_e1_setup_req
(
sctp_assoc_t
assoc_id
,
const
e1ap_setup_req_t
*
req
)
{
{
AssertFatal
(
req
->
supported_plmns
<=
PLMN_LIST_MAX_SIZE
,
"Supported PLMNs is more than PLMN_LIST_MAX_SIZE
\n
"
);
AssertFatal
(
req
->
supported_plmns
<=
PLMN_LIST_MAX_SIZE
,
"Supported PLMNs is more than PLMN_LIST_MAX_SIZE
\n
"
);
gNB_RRC_INST
*
rrc
=
RC
.
nrrrc
[
0
];
gNB_RRC_INST
*
rrc
=
RC
.
nrrrc
[
0
];
...
@@ -184,7 +184,7 @@ int rrc_gNB_process_e1_setup_req(sctp_assoc_t assoc_id, e1ap_setup_req_t *req)
...
@@ -184,7 +184,7 @@ int rrc_gNB_process_e1_setup_req(sctp_assoc_t assoc_id, e1ap_setup_req_t *req)
}
}
for
(
int
i
=
0
;
i
<
req
->
supported_plmns
;
i
++
)
{
for
(
int
i
=
0
;
i
<
req
->
supported_plmns
;
i
++
)
{
PLMN_ID_t
*
id
=
&
req
->
plmn
[
i
].
id
;
const
PLMN_ID_t
*
id
=
&
req
->
plmn
[
i
].
id
;
if
(
rrc
->
configuration
.
mcc
[
i
]
!=
id
->
mcc
||
rrc
->
configuration
.
mnc
[
i
]
!=
id
->
mnc
)
{
if
(
rrc
->
configuration
.
mcc
[
i
]
!=
id
->
mcc
||
rrc
->
configuration
.
mnc
[
i
]
!=
id
->
mnc
)
{
LOG_E
(
NR_RRC
,
LOG_E
(
NR_RRC
,
"PLMNs received from CUUP (mcc:%d, mnc:%d) did not match with PLMNs in RRC (mcc:%d, mnc:%d)
\n
"
,
"PLMNs received from CUUP (mcc:%d, mnc:%d) did not match with PLMNs in RRC (mcc:%d, mnc:%d)
\n
"
,
...
@@ -199,9 +199,8 @@ int rrc_gNB_process_e1_setup_req(sctp_assoc_t assoc_id, e1ap_setup_req_t *req)
...
@@ -199,9 +199,8 @@ int rrc_gNB_process_e1_setup_req(sctp_assoc_t assoc_id, e1ap_setup_req_t *req)
}
}
LOG_I
(
NR_RRC
,
"Accepting new CU-UP ID %ld name %s (assoc_id %d)
\n
"
,
req
->
gNB_cu_up_id
,
req
->
gNB_cu_up_name
,
assoc_id
);
LOG_I
(
NR_RRC
,
"Accepting new CU-UP ID %ld name %s (assoc_id %d)
\n
"
,
req
->
gNB_cu_up_id
,
req
->
gNB_cu_up_name
,
assoc_id
);
nr_rrc_cuup_container_t
*
cuup
=
malloc
(
sizeof
(
*
cuup
));
nr_rrc_cuup_container_t
*
cuup
=
malloc_or_fail
(
sizeof
(
*
cuup
));
AssertFatal
(
cuup
,
"out of memory
\n
"
);
cuup
->
setup_req
=
malloc_or_fail
(
sizeof
(
*
cuup
->
setup_req
));
cuup
->
setup_req
=
malloc
(
sizeof
(
*
cuup
->
setup_req
));
*
cuup
->
setup_req
=
cp_e1ap_cuup_setup_request
(
req
);
*
cuup
->
setup_req
=
cp_e1ap_cuup_setup_request
(
req
);
cuup
->
assoc_id
=
assoc_id
;
cuup
->
assoc_id
=
assoc_id
;
RB_INSERT
(
rrc_cuup_tree
,
&
rrc
->
cuups
,
cuup
);
RB_INSERT
(
rrc_cuup_tree
,
&
rrc
->
cuups
,
cuup
);
...
...
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