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
lizhongxiao
OpenXG-RAN
Commits
a2b881a4
Commit
a2b881a4
authored
Jan 17, 2024
by
Teodora
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
FlexRIC release v2
- update KPM available versions - bool return when reading Service Models
parent
c5aeaf03
Changes
17
Hide whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
54 additions
and
39 deletions
+54
-39
CMakeLists.txt
CMakeLists.txt
+2
-2
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_gtp.c
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_gtp.c
+2
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_gtp.h
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_gtp.h
+1
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_mac.c
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_mac.c
+3
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_mac.h
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_mac.h
+1
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_pdcp.c
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_pdcp.c
+6
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_pdcp.h
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_pdcp.h
+1
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_rlc.c
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_rlc.c
+3
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_rlc.h
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_rlc.h
+1
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_slice.c
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_slice.c
+3
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_slice.h
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_slice.h
+1
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_tc.c
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_tc.c
+3
-1
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_tc.h
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_tc.h
+1
-1
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_kpm.c
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_kpm.c
+21
-22
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_kpm.h
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_kpm.h
+1
-1
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_rc.c
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_rc.c
+3
-1
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_rc.h
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_rc.h
+1
-1
No files found.
CMakeLists.txt
View file @
a2b881a4
...
...
@@ -300,8 +300,8 @@ set(E2AP_VERSION "E2AP_V2" CACHE STRING "E2AP version")
set_property
(
CACHE E2AP_VERSION PROPERTY STRINGS
"E2AP_V1"
"E2AP_V2"
"E2AP_V3"
)
message
(
STATUS
"Selected E2AP_VERSION:
${
E2AP_VERSION
}
"
)
set
(
KPM_VERSION
"KPM_V2"
CACHE STRING
"The KPM SM version to use"
)
set_property
(
CACHE KPM_VERSION PROPERTY STRINGS
"KPM_V2
"
"KPM_V3
"
)
set
(
KPM_VERSION
"KPM_V2
_03
"
CACHE STRING
"The KPM SM version to use"
)
set_property
(
CACHE KPM_VERSION PROPERTY STRINGS
"KPM_V2
_03"
"KPM_V3_00
"
)
message
(
STATUS
"Selected KPM Version:
${
KPM_VERSION
}
"
)
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_gtp.c
View file @
a2b881a4
...
...
@@ -33,7 +33,7 @@
static
const
int
mod_id
=
0
;
void
read_gtp_sm
(
void
*
data
)
bool
read_gtp_sm
(
void
*
data
)
{
assert
(
data
!=
NULL
);
...
...
@@ -80,6 +80,7 @@ void read_gtp_sm(void * data)
i
++
;
}
return
num_ues
>
0
;
}
void
read_gtp_setup_sm
(
void
*
data
)
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_gtp.h
View file @
a2b881a4
...
...
@@ -24,7 +24,7 @@
#include "openair2/E2AP/flexric/src/agent/../sm/sm_io.h"
void
read_gtp_sm
(
void
*
);
bool
read_gtp_sm
(
void
*
);
void
read_gtp_setup_sm
(
void
*
);
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_mac.c
View file @
a2b881a4
...
...
@@ -27,7 +27,7 @@ static
const
int
mod_id
=
0
;
void
read_mac_sm
(
void
*
data
)
bool
read_mac_sm
(
void
*
data
)
{
assert
(
data
!=
NULL
);
...
...
@@ -110,6 +110,8 @@ void read_mac_sm(void* data)
++
i
;
}
return
num_ues
>
0
;
}
void
read_mac_setup_sm
(
void
*
data
)
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_mac.h
View file @
a2b881a4
...
...
@@ -28,7 +28,7 @@
#include "openair2/E2AP/flexric/src/util/time_now_us.h"
void
read_mac_sm
(
void
*
);
bool
read_mac_sm
(
void
*
);
void
read_mac_setup_sm
(
void
*
);
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_pdcp.c
View file @
a2b881a4
...
...
@@ -55,7 +55,7 @@ static
return
act_rb
;
}
void
read_pdcp_sm
(
void
*
data
)
bool
read_pdcp_sm
(
void
*
data
)
{
assert
(
data
!=
NULL
);
//assert(data->type == PDCP_STATS_V0);
...
...
@@ -123,6 +123,9 @@ void read_pdcp_sm(void* data)
++
i
;
}
}
return
act_rb
>
0
;
}
else
{
//assert(0!=0 && "Calling PDCP");
...
...
@@ -176,6 +179,8 @@ void read_pdcp_sm(void* data)
++
i
;
}
}
return
act_rb
>
0
;
}
}
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_pdcp.h
View file @
a2b881a4
...
...
@@ -24,7 +24,7 @@
#include "openair2/E2AP/flexric/src/agent/../sm/sm_io.h"
void
read_pdcp_sm
(
void
*
);
bool
read_pdcp_sm
(
void
*
);
void
read_pdcp_setup_sm
(
void
*
data
);
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_rlc.c
View file @
a2b881a4
...
...
@@ -67,7 +67,7 @@ void active_avg_to_tx(NR_UEs_t* const UE_info)
}
}
void
read_rlc_sm
(
void
*
data
)
bool
read_rlc_sm
(
void
*
data
)
{
assert
(
data
!=
NULL
);
// assert(data->type == RLC_STATS_V0);
...
...
@@ -161,6 +161,8 @@ void read_rlc_sm(void* data)
++
i
;
}
}
return
act_rb
>
0
;
}
void
read_rlc_setup_sm
(
void
*
data
)
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_rlc.h
View file @
a2b881a4
...
...
@@ -24,7 +24,7 @@
#include "openair2/E2AP/flexric/src/agent/../sm/sm_io.h"
void
read_rlc_sm
(
void
*
);
bool
read_rlc_sm
(
void
*
);
void
read_rlc_setup_sm
(
void
*
data
);
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_slice.c
View file @
a2b881a4
...
...
@@ -24,13 +24,15 @@
#include <assert.h>
#include <stdio.h>
void
read_slice_sm
(
void
*
data
)
bool
read_slice_sm
(
void
*
data
)
{
assert
(
data
!=
NULL
);
// assert(data->type == SLICE_STATS_V0);
slice_ind_data_t
*
slice
=
(
slice_ind_data_t
*
)
data
;
fill_slice_ind_data
(
slice
);
return
true
;
}
void
read_slice_setup_sm
(
void
*
data
)
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_slice.h
View file @
a2b881a4
...
...
@@ -24,7 +24,7 @@
#include "openair2/E2AP/flexric/src/agent/../sm/sm_io.h"
void
read_slice_sm
(
void
*
);
bool
read_slice_sm
(
void
*
);
void
read_slice_setup_sm
(
void
*
data
);
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_tc.c
View file @
a2b881a4
...
...
@@ -23,13 +23,15 @@
#include "../../flexric/test/rnd/fill_rnd_data_tc.h"
#include <assert.h>
void
read_tc_sm
(
void
*
data
)
bool
read_tc_sm
(
void
*
data
)
{
assert
(
data
!=
NULL
);
//assert(data->type == TC_STATS_V0);
tc_ind_data_t
*
tc
=
(
tc_ind_data_t
*
)
data
;
fill_tc_ind_data
(
tc
);
return
true
;
}
void
read_tc_setup_sm
(
void
*
data
)
...
...
openair2/E2AP/RAN_FUNCTION/CUSTOMIZED/ran_func_tc.h
View file @
a2b881a4
...
...
@@ -24,7 +24,7 @@
#include "openair2/E2AP/flexric/src/agent/../sm/sm_io.h"
void
read_tc_sm
(
void
*
);
bool
read_tc_sm
(
void
*
);
void
read_tc_setup_sm
(
void
*
data
);
...
...
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_kpm.c
View file @
a2b881a4
...
...
@@ -73,7 +73,7 @@ static size_t filter_ues_by_s_nssai_in_du_or_monolithic(test_cond_e const condit
}
matches
->
num_ues
=
i
;
assert
(
matches
->
num_ues
>=
1
&&
"The number of filtered UEs must be at least equal to 1"
);
return
i
;
}
...
...
@@ -104,7 +104,7 @@ static size_t filter_ues_by_s_nssai_in_cu(test_cond_e const condition, uint8_t s
}
matches
->
num_ues
=
i
;
assert
(
matches
->
num_ues
>=
1
&&
"The number of filtered UEs must be at least equal to 1"
);
return
i
;
}
...
...
@@ -613,9 +613,9 @@ kpm_ric_ind_hdr_format_1_t kpm_ind_hdr_frm_1(void)
kpm_ric_ind_hdr_format_1_t
hdr_frm_1
=
{
0
};
int64_t
const
t
=
time_now_us
();
#if defined KPM_V2
#if defined KPM_V2
_03
hdr_frm_1
.
collectStartTime
=
t
/
1000000
;
// seconds
#elif defined KPM_V3
#elif defined KPM_V3
_00
hdr_frm_1
.
collectStartTime
=
t
;
// microseconds
#else
static_assert
(
0
!=
0
,
"Undefined KPM SM Version"
);
...
...
@@ -690,31 +690,31 @@ static void capture_sst_sd(test_info_lst_t* test, uint8_t *sst, uint32_t **sd)
// we made a mistake in the past: NSSAI is supposed to be an OCTET_STRING,
// but earlier version of the RAN function and the xApp used integer, so
// handle this gracefully by accepting integer as well
switch
(
*
test
->
test_cond_valu
e
)
{
switch
(
test
->
test_cond_value
->
typ
e
)
{
case
INTEGER_TEST_COND_VALUE
:
AssertFatal
(
*
test
->
int_value
<=
0xff
,
"illegal SST %ld
\n
"
,
*
test
->
int_value
);
*
sst
=
*
test
->
int_value
;
AssertFatal
(
*
test
->
test_cond_value
->
int_value
<=
0xff
,
"illegal SST %ld
\n
"
,
*
test
->
test_cond_value
->
int_value
);
*
sst
=
*
test
->
test_cond_value
->
int_value
;
*
sd
=
NULL
;
break
;
case
OCTET_STRING_TEST_COND_VALUE
:
if
(
test
->
octet_string_value
->
len
==
1
)
{
*
sst
=
test
->
octet_string_value
->
buf
[
0
];
if
(
test
->
test_cond_value
->
octet_string_value
->
len
==
1
)
{
*
sst
=
test
->
test_cond_value
->
octet_string_value
->
buf
[
0
];
*
sd
=
NULL
;
}
else
{
DevAssert
(
test
->
octet_string_value
->
len
==
4
);
uint8_t
*
buf
=
test
->
octet_string_value
->
buf
;
DevAssert
(
test
->
test_cond_value
->
octet_string_value
->
len
==
4
);
uint8_t
*
buf
=
test
->
test_cond_value
->
octet_string_value
->
buf
;
*
sst
=
buf
[
0
];
*
sd
=
malloc
(
**
sd
);
**
sd
=
buf
[
1
]
<<
16
|
buf
[
2
]
<<
8
|
buf
[
3
];
}
break
;
default:
AssertFatal
(
false
,
"test condition value %d impossible
\n
"
,
*
test
->
test_cond_valu
e
);
AssertFatal
(
false
,
"test condition value %d impossible
\n
"
,
test
->
test_cond_value
->
typ
e
);
break
;
}
}
void
read_kpm_sm
(
void
*
data
)
bool
read_kpm_sm
(
void
*
data
)
{
assert
(
data
!=
NULL
);
// assert(data->type == KPM_STATS_V3_0);
...
...
@@ -767,9 +767,7 @@ void read_kpm_sm(void* data)
}
case
CQI_TEST_COND_TYPE
:
{
// This is a bad idea. Done only to check FlexRIC xAPP
printf
(
"CQI not implemented!. Randomly filling the data
\n
"
);
goto
rnd_data_label
;
assert
(
0
!=
0
&&
"Not implemented"
);
break
;
}
...
...
@@ -786,7 +784,7 @@ void read_kpm_sm(void* data)
case
S_NSSAI_TEST_COND_TYPE
:
{
assert
(
frm_4
->
matching_cond_lst
[
i
].
test_info_lst
.
S_NSSAI
==
TRUE_TEST_COND_TYPE
&&
"Must be true"
);
assert
(
frm_4
->
matching_cond_lst
[
i
].
test_info_lst
.
test_cond
!=
NULL
&&
"Even though is optional.."
);
assert
(
frm_4
->
matching_cond_lst
[
i
].
test_info_lst
.
int
_value
!=
NULL
&&
"Even though is optional.."
);
assert
(
frm_4
->
matching_cond_lst
[
i
].
test_info_lst
.
test_cond
_value
!=
NULL
&&
"Even though is optional.."
);
test_cond_e
const
test_cond
=
*
frm_4
->
matching_cond_lst
[
i
].
test_info_lst
.
test_cond
;
uint8_t
sst
=
0
;
...
...
@@ -796,14 +794,17 @@ void read_kpm_sm(void* data)
if
(
NODE_IS_DU
(
RC
.
nrrrc
[
0
]
->
node_type
))
{
matched_ues_mac_t
matched_ues
=
{
0
};
matched_ues
.
num_ues
=
filter_ues_by_s_nssai_in_du_or_monolithic
(
test_cond
,
sst
,
sd
,
&
matched_ues
);
if
(
matched_ues
.
num_ues
==
0
)
return
false
;
kpm
->
ind
.
msg
.
frm_3
=
fill_kpm_ind_msg_frm_3_in_du
(
&
matched_ues
,
&
frm_4
->
action_def_format_1
);
}
else
if
(
NODE_IS_CU
(
RC
.
nrrrc
[
0
]
->
node_type
))
{
matched_ues_rrc_t
matched_ues
=
{
0
};
matched_ues
.
num_ues
=
filter_ues_by_s_nssai_in_cu
(
test_cond
,
sst
,
sd
,
&
matched_ues
);
if
(
matched_ues
.
num_ues
==
0
)
return
false
;
kpm
->
ind
.
msg
.
frm_3
=
fill_kpm_ind_msg_frm_3_in_cu
(
&
matched_ues
,
&
frm_4
->
action_def_format_1
);
}
else
if
(
NODE_IS_MONOLITHIC
(
RC
.
nrrrc
[
0
]
->
node_type
))
{
matched_ues_mac_t
matched_ues
=
{
0
};
matched_ues
.
num_ues
=
filter_ues_by_s_nssai_in_du_or_monolithic
(
test_cond
,
sst
,
sd
,
&
matched_ues
);
if
(
matched_ues
.
num_ues
==
0
)
return
false
;
kpm
->
ind
.
msg
.
frm_3
=
fill_kpm_ind_msg_frm_3_in_monolithic
(
&
matched_ues
,
&
frm_4
->
action_def_format_1
);
}
else
{
assert
(
false
&&
"NG-RAN Type not implemented"
);
...
...
@@ -822,13 +823,11 @@ void read_kpm_sm(void* data)
}
default:
{
rnd_data_label:
kpm
->
ind
.
hdr
=
fill_rnd_kpm_ind_hdr
();
kpm
->
ind
.
msg
=
fill_rnd_kpm_ind_msg
();
break
;
AssertFatal
(
kpm
->
act_def
->
type
==
FORMAT_4_ACTION_DEFINITION
,
"Action Definition Format %d not yet implemented"
,
kpm
->
act_def
->
type
);
}
}
return
true
;
}
void
read_kpm_setup_sm
(
void
*
e2ap
)
...
...
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_kpm.h
View file @
a2b881a4
...
...
@@ -24,7 +24,7 @@
#include "openair2/E2AP/flexric/src/agent/../sm/sm_io.h"
void
read_kpm_sm
(
void
*
);
bool
read_kpm_sm
(
void
*
);
void
read_kpm_setup_sm
(
void
*
);
...
...
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_rc.c
View file @
a2b881a4
...
...
@@ -30,11 +30,13 @@
#include <pthread.h>
#include <unistd.h>
void
read_rc_sm
(
void
*
data
)
bool
read_rc_sm
(
void
*
data
)
{
assert
(
data
!=
NULL
);
// assert(data->type == RAN_CTRL_STATS_V1_03);
assert
(
0
!=
0
&&
"Not implemented"
);
return
true
;
}
void
read_rc_setup_sm
(
void
*
data
)
...
...
openair2/E2AP/RAN_FUNCTION/O-RAN/ran_func_rc.h
View file @
a2b881a4
...
...
@@ -24,7 +24,7 @@
#include "openair2/E2AP/flexric/src/agent/../sm/sm_io.h"
void
read_rc_sm
(
void
*
);
bool
read_rc_sm
(
void
*
);
void
read_rc_setup_sm
(
void
*
data
);
...
...
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