Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
O
OpenXG UE
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
OpenXG UE
Commits
c89162dd
Commit
c89162dd
authored
Jun 24, 2020
by
Andrew Burger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adding ul_config_req cleanup and hi_dci0_req
parent
07ac0262
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
171 additions
and
133 deletions
+171
-133
ci-scripts/conf_files/ue.nfapi.conf
ci-scripts/conf_files/ue.nfapi.conf
+3
-3
openair2/PHY_INTERFACE/phy_stub_UE.c
openair2/PHY_INTERFACE/phy_stub_UE.c
+163
-126
targets/RT/USER/lte-ue.c
targets/RT/USER/lte-ue.c
+5
-4
No files found.
ci-scripts/conf_files/ue.nfapi.conf
View file @
c89162dd
log_config
= {
global_log_level
=
"
info
"
;
global_log_level
=
"
debug
"
;
global_log_verbosity
=
"medium"
;
hw_log_level
=
"info"
;
hw_log_verbosity
=
"medium"
;
phy_log_level
=
"
info
"
;
phy_log_level
=
"
debug
"
;
phy_log_verbosity
=
"medium"
;
mac_log_level
=
"
info
"
;
mac_log_level
=
"
debug
"
;
mac_log_verbosity
=
"medium"
;
rlc_log_level
=
"info"
;
rlc_log_verbosity
=
"medium"
;
...
...
openair2/PHY_INTERFACE/phy_stub_UE.c
View file @
c89162dd
...
...
@@ -43,9 +43,6 @@ void configure_nfapi_pnf(char *vnf_ip_addr,
UL_IND_t
*
UL_INFO
=
NULL
;
nfapi_ul_config_request_t
*
ul_config_req
=
NULL
;
nfapi_hi_dci0_request_t
*
hi_dci0_req
=
NULL
;
queue_t
dl_config_req_queue
;
queue_t
tx_req_pdu_queue
;
queue_t
ul_config_req_queue
;
...
...
@@ -71,7 +68,8 @@ void fill_rx_indication_UE_MAC(module_id_t Mod_id,
uint8_t
*
ulsch_buffer
,
uint16_t
buflen
,
uint16_t
rnti
,
int
index
)
{
int
index
,
nfapi_ul_config_request_t
*
ul_config_req
)
{
nfapi_rx_indication_pdu_t
*
pdu
;
int
timing_advance_update
;
...
...
@@ -119,7 +117,8 @@ void fill_sr_indication_UE_MAC(int Mod_id,
int
frame
,
int
subframe
,
UL_IND_t
*
UL_INFO
,
uint16_t
rnti
)
{
uint16_t
rnti
,
nfapi_ul_config_request_t
*
ul_config_req
)
{
pthread_mutex_lock
(
&
fill_ul_mutex
.
sr_mutex
);
nfapi_sr_indication_t
*
sr_ind
=
&
UL_INFO
->
sr_ind
;
...
...
@@ -159,7 +158,8 @@ void fill_crc_indication_UE_MAC(int Mod_id,
UL_IND_t
*
UL_INFO
,
uint8_t
crc_flag
,
int
index
,
uint16_t
rnti
)
{
uint16_t
rnti
,
nfapi_ul_config_request_t
*
ul_config_req
)
{
pthread_mutex_lock
(
&
fill_ul_mutex
.
crc_mutex
);
nfapi_crc_indication_pdu_t
*
pdu
=
...
...
@@ -302,7 +302,8 @@ void fill_ulsch_harq_indication_UE_MAC(
int
subframe
,
UL_IND_t
*
UL_INFO
,
nfapi_ul_config_ulsch_harq_information
*
harq_information
,
uint16_t
rnti
)
{
uint16_t
rnti
,
nfapi_ul_config_request_t
*
ul_config_req
)
{
pthread_mutex_lock
(
&
fill_ul_mutex
.
harq_mutex
);
nfapi_harq_indication_pdu_t
*
pdu
=
...
...
@@ -344,7 +345,8 @@ void fill_uci_harq_indication_UE_MAC(int Mod_id,
int
subframe
,
UL_IND_t
*
UL_INFO
,
nfapi_ul_config_harq_information
*
harq_information
,
uint16_t
rnti
)
{
uint16_t
rnti
,
nfapi_ul_config_request_t
*
ul_config_req
)
{
pthread_mutex_lock
(
&
fill_ul_mutex
.
harq_mutex
);
nfapi_harq_indication_t
*
ind
=
&
UL_INFO
->
harq_ind
;
...
...
@@ -902,9 +904,8 @@ void hi_dci0_req_UE_MAC(int sfn,
// The following set of memcpy functions should be getting called as callback
// functions from pnf_p7_subframe_ind.
int
memcpy_dl_config_req
(
L1_rxtx_proc_t
*
proc
,
nfapi_pnf_p7_config_t
*
pnf_p7
,
nfapi_dl_config_request_t
*
req
)
{
int
memcpy_dl_config_req
(
L1_rxtx_proc_t
*
proc
,
nfapi_pnf_p7_config_t
*
pnf_p7
,
nfapi_dl_config_request_t
*
req
)
{
nfapi_dl_config_request_t
*
p
=
malloc
(
sizeof
(
nfapi_dl_config_request_t
));
...
...
@@ -957,12 +958,9 @@ int memcpy_ul_config_req (L1_rxtx_proc_t *proc, nfapi_pnf_p7_config_t* pnf_p7, n
req
->
ul_config_request_body
.
ul_config_pdu_list
[
i
];
}
#if 0 // TODO not using queue here yet
if
(
!
put_queue
(
&
ul_config_req_queue
,
p
))
{
free
(
p
);
}
#endif
ul_config_req
=
p
;
return
0
;
}
...
...
@@ -984,6 +982,7 @@ int memcpy_tx_req(nfapi_pnf_p7_config_t *pnf_p7, nfapi_tx_request_t *req) {
}
}
}
if
(
!
put_queue
(
&
tx_req_pdu_queue
,
p
))
{
free
(
p
);
}
...
...
@@ -991,9 +990,8 @@ int memcpy_tx_req(nfapi_pnf_p7_config_t *pnf_p7, nfapi_tx_request_t *req) {
return
0
;
}
int
memcpy_hi_dci0_req
(
L1_rxtx_proc_t
*
proc
,
nfapi_pnf_p7_config_t
*
pnf_p7
,
nfapi_hi_dci0_request_t
*
req
)
{
int
memcpy_hi_dci0_req
(
L1_rxtx_proc_t
*
proc
,
nfapi_pnf_p7_config_t
*
pnf_p7
,
nfapi_hi_dci0_request_t
*
req
)
{
nfapi_hi_dci0_request_t
*
p
=
(
nfapi_hi_dci0_request_t
*
)
malloc
(
sizeof
(
nfapi_hi_dci0_request_t
));
//if(req!=0){
...
...
@@ -1023,12 +1021,9 @@ int memcpy_hi_dci0_req (L1_rxtx_proc_t *proc,
// UE_mac_inst[Mod_id].p->hi_dci0_request_body.hi_dci0_pdu_list[i].pdu_type);
}
#if 0 // TODO not using queue here yet
if
(
!
put_queue
(
&
hi_dci0_req_queue
,
p
))
{
free
(
p
);
}
#endif
hi_dci0_req
=
p
;
return
0
;
}
...
...
@@ -1178,8 +1173,36 @@ void *ue_standalone_pnf_task(void *context)
break
;
}
case
NFAPI_HI_DCI0_REQUEST
:
{
nfapi_hi_dci0_request_t
hi_dci0_req
;
// lock this hi_dci0_req
if
(
nfapi_p7_message_unpack
((
void
*
)
buffer
,
len
,
&
hi_dci0_req
,
sizeof
(
hi_dci0_req
),
NULL
)
<
0
)
{
LOG_E
(
MAC
,
"Message hi_dci0_req failed to unpack
\n
"
);
}
else
{
// check to see if hi_dci0_req is null
memcpy_hi_dci0_req
(
NULL
,
NULL
,
&
hi_dci0_req
);
}
break
;
}
case
NFAPI_UL_CONFIG_REQUEST
:
{
nfapi_ul_config_request_t
ul_config_req
;
// lock this ul_config_req
if
(
nfapi_p7_message_unpack
((
void
*
)
buffer
,
len
,
&
ul_config_req
,
sizeof
(
ul_config_req
),
NULL
)
<
0
)
{
LOG_E
(
MAC
,
"Message ul_config_req failed to unpack
\n
"
);
}
else
{
// check to see if ul_config_req is null
memcpy_ul_config_req
(
NULL
,
NULL
,
&
ul_config_req
);
}
}
default:
LOG_E
(
MAC
,
"Case Statement has no corresponding nfapi message
\n
"
);
break
;
...
...
@@ -1188,8 +1211,8 @@ void *ue_standalone_pnf_task(void *context)
}
}
void
send_standalone_msg
(
UL_IND_t
*
UL
,
nfapi_message_id_e
msg_type
)
{
void
send_standalone_msg
(
UL_IND_t
*
UL
,
nfapi_message_id_e
msg_type
)
{
int
encoded_size
=
-
1
;
char
buffer
[
1024
];
switch
(
msg_type
)
...
...
@@ -1225,91 +1248,105 @@ void send_standalone_msg(UL_IND_t *UL, nfapi_message_id_e msg_type)
LOG_E
(
MAC
,
"Send Proxy UE failed
\n
"
);
return
;
}
}
}
void
send_standalone_dummy
()
{
void
send_standalone_dummy
()
{
static
const
uint16_t
dummy
[]
=
{
0
,
0
};
if
(
send
(
ue_sock_descriptor
,
dummy
,
sizeof
(
dummy
),
0
)
<
0
)
{
LOG_E
(
MAC
,
"send dummy to OAI UE failed: %s
\n
"
,
strerror
(
errno
));
return
;
}
}
}
/* Dummy functions*/
/* Dummy functions*/
void
handle_nfapi_hi_dci0_dci_pdu
(
PHY_VARS_eNB
*
eNB
,
void
handle_nfapi_hi_dci0_dci_pdu
(
PHY_VARS_eNB
*
eNB
,
int
frame
,
int
subframe
,
L1_rxtx_proc_t
*
proc
,
nfapi_hi_dci0_request_pdu_t
*
hi_dci0_config_pdu
)
{
}
nfapi_hi_dci0_request_pdu_t
*
hi_dci0_config_pdu
)
{
}
void
handle_nfapi_hi_dci0_hi_pdu
(
PHY_VARS_eNB
*
eNB
,
void
handle_nfapi_hi_dci0_hi_pdu
(
PHY_VARS_eNB
*
eNB
,
int
frame
,
int
subframe
,
L1_rxtx_proc_t
*
proc
,
nfapi_hi_dci0_request_pdu_t
*
hi_dci0_config_pdu
)
{
}
nfapi_hi_dci0_request_pdu_t
*
hi_dci0_config_pdu
)
{
}
void
handle_nfapi_dci_dl_pdu
(
PHY_VARS_eNB
*
eNB
,
void
handle_nfapi_dci_dl_pdu
(
PHY_VARS_eNB
*
eNB
,
int
frame
,
int
subframe
,
L1_rxtx_proc_t
*
proc
,
nfapi_dl_config_request_pdu_t
*
dl_config_pdu
)
{
}
nfapi_dl_config_request_pdu_t
*
dl_config_pdu
)
{
}
void
handle_nfapi_bch_pdu
(
PHY_VARS_eNB
*
eNB
,
L1_rxtx_proc_t
*
proc
,
nfapi_dl_config_request_pdu_t
*
dl_config_pdu
,
uint8_t
*
sdu
)
{
}
void
handle_nfapi_bch_pdu
(
PHY_VARS_eNB
*
eNB
,
L1_rxtx_proc_t
*
proc
,
nfapi_dl_config_request_pdu_t
*
dl_config_pdu
,
uint8_t
*
sdu
)
{
}
void
handle_nfapi_dlsch_pdu
(
PHY_VARS_eNB
*
eNB
,
void
handle_nfapi_dlsch_pdu
(
PHY_VARS_eNB
*
eNB
,
int
frame
,
int
subframe
,
L1_rxtx_proc_t
*
proc
,
nfapi_dl_config_request_pdu_t
*
dl_config_pdu
,
uint8_t
codeword_index
,
uint8_t
*
sdu
)
{
}
uint8_t
*
sdu
)
{
}
void
handle_nfapi_ul_pdu
(
PHY_VARS_eNB
*
eNB
,
L1_rxtx_proc_t
*
proc
,
nfapi_ul_config_request_pdu_t
*
ul_config_pdu
,
void
handle_nfapi_ul_pdu
(
PHY_VARS_eNB
*
eNB
,
L1_rxtx_proc_t
*
proc
,
nfapi_ul_config_request_pdu_t
*
ul_config_pdu
,
uint16_t
frame
,
uint8_t
subframe
,
uint8_t
srs_present
)
{
}
void
handle_nfapi_mch_pdu
(
PHY_VARS_eNB
*
eNB
,
L1_rxtx_proc_t
*
proc
,
nfapi_dl_config_request_pdu_t
*
dl_config_pdu
,
uint8_t
*
sdu
)
{
}
uint8_t
srs_present
)
{
}
void
handle_nfapi_mch_pdu
(
PHY_VARS_eNB
*
eNB
,
L1_rxtx_proc_t
*
proc
,
nfapi_dl_config_request_pdu_t
*
dl_config_pdu
,
uint8_t
*
sdu
)
{
}
void
phy_config_request
(
PHY_Config_t
*
phy_config
)
{
}
void
phy_config_request
(
PHY_Config_t
*
phy_config
)
{
}
void
phy_config_update_sib2_request
(
PHY_Config_t
*
phy_config
)
{
}
void
phy_config_update_sib2_request
(
PHY_Config_t
*
phy_config
)
{
}
void
phy_config_update_sib13_request
(
PHY_Config_t
*
phy_config
)
{
}
void
phy_config_update_sib13_request
(
PHY_Config_t
*
phy_config
)
{
}
uint32_t
from_earfcn
(
int
eutra_bandP
,
uint32_t
dl_earfcn
)
{
uint32_t
from_earfcn
(
int
eutra_bandP
,
uint32_t
dl_earfcn
)
{
return
(
0
);
}
}
int32_t
get_uldl_offset
(
int
eutra_bandP
)
{
int32_t
get_uldl_offset
(
int
eutra_bandP
)
{
return
(
0
);
}
}
int
l1_north_init_eNB
(
void
)
{
int
l1_north_init_eNB
(
void
)
{
return
0
;
}
}
void
init_eNB_afterRU
(
void
)
{
}
void
init_eNB_afterRU
(
void
)
{
}
targets/RT/USER/lte-ue.c
View file @
c89162dd
...
...
@@ -1029,8 +1029,6 @@ static void *UE_phy_stub_standalone_pnf_task(void *arg)
proc
->
subframe_rx
=
proc
->
sub_frame_start
;
// Initializations for nfapi-L2-emulator mode
ul_config_req
=
NULL
;
hi_dci0_req
=
NULL
;
sync_var
=
0
;
//PANOS: CAREFUL HERE!
...
...
@@ -1059,6 +1057,8 @@ static void *UE_phy_stub_standalone_pnf_task(void *arg)
nfapi_dl_config_request_t
*
dl_config_req
=
get_queue
(
&
dl_config_req_queue
);
nfapi_tx_request_pdu_t
*
tx_request_pdu_list
=
get_queue
(
&
tx_req_pdu_queue
);
nfapi_ul_config_request_t
*
ul_config_req
=
get_queue
(
&
ul_config_req_queue
);
nfapi_hi_dci0_request_t
*
hi_dci0_req
=
get_queue
(
&
hi_dci0_req_queue
);
if
((
dl_config_req
!=
NULL
)
!=
(
tx_request_pdu_list
!=
NULL
))
{
uint64_t
start
=
clock_usec
();
uint64_t
deadline
=
start
+
10000
;
...
...
@@ -1786,6 +1786,7 @@ static void *UE_phy_stub_single_thread_rxn_txnp4(void *arg)
static
void
*
UE_phy_stub_thread_rxn_txnp4
(
void
*
arg
)
{
#if 0
thread_top_init("UE_phy_stub_thread_rxn_txnp4",1,870000L,1000000L,1000000L);
module_id_t Mod_id = 0;
static __thread int UE_thread_rxtx_retval;
...
...
@@ -1929,10 +1930,10 @@ static void *UE_phy_stub_thread_rxn_txnp4(void *arg)
phy_procedures_UE_SL_RX(UE,proc);
}
#endif // disabled
// thread finished
free
(
arg
);
return
&
UE_thread_rxtx_retval
;
return
NULL
;
//return
&UE_thread_rxtx_retval;
}
...
...
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