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
d220ee23
Commit
d220ee23
authored
May 26, 2023
by
Robert Schmidt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
UL RRC Message has CU/DU UE IDs
parent
09438910
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
45 additions
and
14 deletions
+45
-14
openair2/COMMON/f1ap_messages_types.h
openair2/COMMON/f1ap_messages_types.h
+2
-1
openair2/F1AP/f1ap_cu_rrc_message_transfer.c
openair2/F1AP/f1ap_cu_rrc_message_transfer.c
+11
-1
openair2/F1AP/f1ap_du_rrc_message_transfer.c
openair2/F1AP/f1ap_du_rrc_message_transfer.c
+11
-7
openair2/LAYER2/nr_pdcp/nr_pdcp_oai_api.c
openair2/LAYER2/nr_pdcp/nr_pdcp_oai_api.c
+6
-1
openair2/LAYER2/nr_rlc/nr_rlc_oai_api.c
openair2/LAYER2/nr_rlc/nr_rlc_oai_api.c
+13
-3
openair2/RRC/NR/rrc_gNB.c
openair2/RRC/NR/rrc_gNB.c
+2
-1
No files found.
openair2/COMMON/f1ap_messages_types.h
View file @
d220ee23
...
...
@@ -317,7 +317,8 @@ typedef struct f1ap_initial_ul_rrc_message_s {
}
f1ap_initial_ul_rrc_message_t
;
typedef
struct
f1ap_ul_rrc_message_s
{
uint16_t
rnti
;
uint32_t
gNB_CU_ue_id
;
uint32_t
gNB_DU_ue_id
;
uint8_t
srb_id
;
uint8_t
*
rrc_container
;
int
rrc_container_length
;
...
...
openair2/F1AP/f1ap_cu_rrc_message_transfer.c
View file @
d220ee23
...
...
@@ -32,6 +32,7 @@
#include "f1ap_common.h"
#include "f1ap_encoder.h"
#include "f1ap_ids.h"
#include "f1ap_itti_messaging.h"
#include "f1ap_cu_rrc_message_transfer.h"
#include "common/ran_context.h"
...
...
@@ -253,6 +254,15 @@ int CU_handle_UL_RRC_MESSAGE_TRANSFER(instance_t instance,
du_ue_f1ap_id
=
ie
->
value
.
choice
.
GNB_DU_UE_F1AP_ID
;
LOG_D
(
F1AP
,
"du_ue_f1ap_id %lu associated with RNTI %x
\n
"
,
du_ue_f1ap_id
,
f1ap_get_rnti_by_cu_id
(
CUtype
,
instance
,
du_ue_f1ap_id
));
/* the RLC-PDCP does not transport the DU UE ID (yet), so we drop it here.
* For the moment, let's hope this won't become relevant; to sleep in peace,
* let's put an assert to check that it is the expected DU UE ID. */
f1_ue_data_t
ue_data
=
cu_get_f1_ue_data
(
cu_ue_f1ap_id
);
AssertFatal
(
ue_data
.
secondary_ue
==
du_ue_f1ap_id
,
"unexpected DU UE ID %d received, expected it to be %ld
\n
"
,
ue_data
.
secondary_ue
,
du_ue_f1ap_id
);
/* mandatory */
/* SRBID */
F1AP_FIND_PROTOCOLIE_BY_ID
(
F1AP_ULRRCMessageTransferIEs_t
,
ie
,
container
,
...
...
@@ -272,7 +282,7 @@ int CU_handle_UL_RRC_MESSAGE_TRANSFER(instance_t instance,
protocol_ctxt_t
ctxt
=
{
0
};
ctxt
.
instance
=
instance
;
ctxt
.
module_id
=
instance
;
ctxt
.
rntiMaybeUEid
=
f1ap_get_rnti_by_cu_id
(
CUtype
,
instance
,
cu_ue_f1ap_id
)
;
ctxt
.
rntiMaybeUEid
=
cu_ue_f1ap_id
;
ctxt
.
enb_flag
=
1
;
ctxt
.
eNB_index
=
0
;
mem_block_t
*
mb
=
get_free_mem_block
(
ie
->
value
.
choice
.
RRCContainer
.
size
,
__func__
);
...
...
openair2/F1AP/f1ap_du_rrc_message_transfer.c
View file @
d220ee23
...
...
@@ -220,15 +220,19 @@ int DU_send_INITIAL_UL_RRC_MESSAGE_TRANSFER(instance_t instanceP, const f1ap_ini
return
0
;
}
int
DU_send_UL_NR_RRC_MESSAGE_TRANSFER
(
instance_t
instance
,
const
f1ap_ul_rrc_message_t
*
msg
)
{
const
rnti_t
rnti
=
msg
->
rnti
;
int
DU_send_UL_NR_RRC_MESSAGE_TRANSFER
(
instance_t
instance
,
const
f1ap_ul_rrc_message_t
*
msg
)
{
F1AP_F1AP_PDU_t
pdu
=
{
0
};
F1AP_ULRRCMessageTransfer_t
*
out
;
uint8_t
*
buffer
=
NULL
;
uint32_t
len
;
LOG_D
(
F1AP
,
"[DU %ld] %s: size %d UE RNTI %x in SRB %d
\n
"
,
instance
,
__func__
,
msg
->
rrc_container_length
,
rnti
,
msg
->
srb_id
);
LOG_D
(
F1AP
,
"[DU %ld] %s: size %d UE RNTI %x in SRB %d
\n
"
,
instance
,
__func__
,
msg
->
rrc_container_length
,
msg
->
gNB_DU_ue_id
,
msg
->
srb_id
);
//for (int i = 0;i < msg->rrc_container_length; i++)
// printf("%02x ", msg->rrc_container[i]);
//printf("\n");
...
...
@@ -246,14 +250,14 @@ int DU_send_UL_NR_RRC_MESSAGE_TRANSFER(instance_t instance,
ie1
->
id
=
F1AP_ProtocolIE_ID_id_gNB_CU_UE_F1AP_ID
;
ie1
->
criticality
=
F1AP_Criticality_reject
;
ie1
->
value
.
present
=
F1AP_ULRRCMessageTransferIEs__value_PR_GNB_CU_UE_F1AP_ID
;
ie1
->
value
.
choice
.
GNB_CU_UE_F1AP_ID
=
f1ap_get_cu_ue_f1ap_id
(
DUtype
,
instance
,
rnti
)
;
ie1
->
value
.
choice
.
GNB_CU_UE_F1AP_ID
=
msg
->
gNB_CU_ue_id
;
/* mandatory */
/* c2. GNB_DU_UE_F1AP_ID */
asn1cSequenceAdd
(
out
->
protocolIEs
.
list
,
F1AP_ULRRCMessageTransferIEs_t
,
ie2
);
ie2
->
id
=
F1AP_ProtocolIE_ID_id_gNB_DU_UE_F1AP_ID
;
ie2
->
criticality
=
F1AP_Criticality_reject
;
ie2
->
value
.
present
=
F1AP_ULRRCMessageTransferIEs__value_PR_GNB_DU_UE_F1AP_ID
;
ie2
->
value
.
choice
.
GNB_DU_UE_F1AP_ID
=
f1ap_get_du_ue_f1ap_id
(
DUtype
,
instance
,
rnti
)
;
ie2
->
value
.
choice
.
GNB_DU_UE_F1AP_ID
=
msg
->
gNB_DU_ue_id
;
/* mandatory */
/* c3. SRBID */
asn1cSequenceAdd
(
out
->
protocolIEs
.
list
,
F1AP_ULRRCMessageTransferIEs_t
,
ie3
);
...
...
openair2/LAYER2/nr_pdcp/nr_pdcp_oai_api.c
View file @
d220ee23
...
...
@@ -36,6 +36,7 @@
#include "oai_asn1.h"
#include "nr_pdcp_oai_api.h"
#include "LAYER2/nr_rlc/nr_rlc_oai_api.h"
#include "openair2/F1AP/f1ap_ids.h"
#include <openair3/ocp-gtpu/gtp_itf.h>
#include "openair2/SDAP/nr_sdap/nr_sdap.h"
#include "nr_pdcp_e1_api.h"
...
...
@@ -710,7 +711,11 @@ srb_found:
MessageDef
*
message_p
=
itti_alloc_new_message
(
TASK_PDCP_GNB
,
0
,
F1AP_UL_RRC_MESSAGE
);
AssertFatal
(
message_p
!=
NULL
,
"OUT OF MEMORY
\n
"
);
f1ap_ul_rrc_message_t
*
ul_rrc
=
&
F1AP_UL_RRC_MESSAGE
(
message_p
);
ul_rrc
->
rnti
=
ue
->
rntiMaybeUEid
;
ul_rrc
->
gNB_CU_ue_id
=
ue
->
rntiMaybeUEid
;
/* look up the correct secondary UE ID to provide complete information to
* RRC, the RLC-PDCP interface does not transport this information */
f1_ue_data_t
ue_data
=
cu_get_f1_ue_data
(
ue
->
rntiMaybeUEid
);
ul_rrc
->
gNB_DU_ue_id
=
ue_data
.
secondary_ue
;
ul_rrc
->
srb_id
=
srb_id
;
ul_rrc
->
rrc_container
=
malloc
(
size
);
AssertFatal
(
ul_rrc
->
rrc_container
!=
NULL
,
"OUT OF MEMORY
\n
"
);
...
...
openair2/LAYER2/nr_rlc/nr_rlc_oai_api.c
View file @
d220ee23
...
...
@@ -39,6 +39,7 @@
#include "NR_UL-CCCH-Message.h"
#include "openair2/F1AP/f1ap_du_rrc_message_transfer.h"
#include "openair2/F1AP/f1ap_ids.h"
extern
RAN_CONTEXT_t
RC
;
...
...
@@ -425,11 +426,18 @@ rb_found:
ctx
.
eNB_index
=
0
;
ctx
.
brOption
=
0
;
is_enb
=
nr_rlc_manager_get_enb_flag
(
nr_rlc_ue_manager
);
/* used fields? */
ctx
.
module_id
=
0
;
/* CU (PDCP, RRC, SDAP) use a different ID than RNTI, so below set the CU UE
* ID if in gNB, else use RNTI normally */
ctx
.
rntiMaybeUEid
=
ue
->
rnti
;
if
(
is_enb
)
{
f1_ue_data_t
ue_data
=
du_get_f1_ue_data
(
ue
->
rnti
);
ctx
.
rntiMaybeUEid
=
ue_data
.
secondary_ue
;
}
is_enb
=
nr_rlc_manager_get_enb_flag
(
nr_rlc_ue_manager
);
ctx
.
enb_flag
=
is_enb
;
if
(
is_enb
)
{
...
...
@@ -453,7 +461,8 @@ rb_found:
msg
=
itti_alloc_new_message
(
TASK_RLC_ENB
,
0
,
F1AP_UL_RRC_MESSAGE
);
uint8_t
*
message_buffer
=
itti_malloc
(
TASK_RLC_ENB
,
TASK_DU_F1
,
size
);
memcpy
(
message_buffer
,
buf
,
size
);
F1AP_UL_RRC_MESSAGE
(
msg
).
rnti
=
ue
->
rnti
;
F1AP_UL_RRC_MESSAGE
(
msg
).
gNB_CU_ue_id
=
ctx
.
rntiMaybeUEid
;
F1AP_UL_RRC_MESSAGE
(
msg
).
gNB_DU_ue_id
=
ue
->
rnti
;
F1AP_UL_RRC_MESSAGE
(
msg
).
srb_id
=
rb_id
;
F1AP_UL_RRC_MESSAGE
(
msg
).
rrc_container
=
message_buffer
;
F1AP_UL_RRC_MESSAGE
(
msg
).
rrc_container_length
=
size
;
...
...
@@ -467,7 +476,7 @@ rb_found:
memcpy
(
req
->
buffer
,
buf
,
size
);
req
->
length
=
size
;
req
->
offset
=
0
;
req
->
ue_id
=
ue
->
rnti
;
req
->
ue_id
=
ctx
.
rntiMaybeUEid
;
req
->
bearer_id
=
rb_id
;
LOG_D
(
RLC
,
"Received uplink user-plane traffic at RLC-DU to be sent to the CU, size %d
\n
"
,
size
);
extern
instance_t
DUuniqInstance
;
...
...
@@ -477,6 +486,7 @@ rb_found:
}
}
/* UE or monolithic gNB */
memblock
=
get_free_mem_block
(
size
,
__func__
);
if
(
memblock
==
NULL
)
{
LOG_E
(
RLC
,
"%s:%d:%s: ERROR: get_free_mem_block failed
\n
"
,
__FILE__
,
__LINE__
,
__FUNCTION__
);
...
...
openair2/RRC/NR/rrc_gNB.c
View file @
d220ee23
...
...
@@ -2754,7 +2754,7 @@ void *rrc_gnb_task(void *args_p) {
PROTOCOL_CTXT_SET_BY_INSTANCE
(
&
ctxt
,
instance
,
GNB_FLAG_YES
,
F1AP_UL_RRC_MESSAGE
(
msg_p
).
rnti
,
F1AP_UL_RRC_MESSAGE
(
msg_p
).
gNB_CU_ue_id
,
0
,
0
);
LOG_D
(
NR_RRC
,
...
...
@@ -2764,6 +2764,7 @@ void *rrc_gnb_task(void *args_p) {
instance
,
&
ctxt
,
F1AP_UL_RRC_MESSAGE
(
msg_p
).
rrc_container_length
);
DevAssert
(
F1AP_UL_RRC_MESSAGE
(
msg_p
).
gNB_CU_ue_id
==
F1AP_UL_RRC_MESSAGE
(
msg_p
).
gNB_DU_ue_id
);
rrc_gNB_decode_dcch
(
&
ctxt
,
F1AP_UL_RRC_MESSAGE
(
msg_p
).
srb_id
,
F1AP_UL_RRC_MESSAGE
(
msg_p
).
rrc_container
,
...
...
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