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
常顺宇
OpenXG-RAN
Commits
11fd202d
Commit
11fd202d
authored
Jan 19, 2019
by
laurent
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix compilation, attach complete
parent
c17f65f1
Changes
5
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
418 additions
and
265 deletions
+418
-265
openair1/SIMULATION/ETH_TRANSPORT/netlink_init.c
openair1/SIMULATION/ETH_TRANSPORT/netlink_init.c
+1
-1
openair2/RRC/LTE/rrc_UE.c
openair2/RRC/LTE/rrc_UE.c
+3
-0
targets/ARCH/rfsimulator/simulator.c
targets/ARCH/rfsimulator/simulator.c
+3
-1
targets/ARCH/tcp_bridge/tcp_bridge_oai.c
targets/ARCH/tcp_bridge/tcp_bridge_oai.c
+382
-244
targets/RT/USER/lte-ue.c
targets/RT/USER/lte-ue.c
+29
-19
No files found.
openair1/SIMULATION/ETH_TRANSPORT/netlink_init.c
View file @
11fd202d
...
...
@@ -63,7 +63,7 @@ struct msghdr nas_msg_tx;
struct
msghdr
nas_msg_rx
;
#define GRAAL_NETLINK_ID 31
#ifdef UE_NAS_USE_TUN
static
int
tun_alloc
(
char
*
dev
)
...
...
openair2/RRC/LTE/rrc_UE.c
View file @
11fd202d
...
...
@@ -3299,6 +3299,7 @@ int decode_SIB1( const protocol_ctxt_t* const ctxt_pP, const uint8_t eNB_index,
msg_p
=
itti_alloc_new_message
(
TASK_RRC_UE
,
PHY_FIND_NEXT_CELL_REQ
);
itti_send_msg_to_task
(
TASK_PHY_UE
,
ctxt_pP
->
instance
,
msg_p
);
LOG_E
(
RRC
,
"Synched with a cell, but PLMN doesn't match our SIM, the message PHY_FIND_NEXT_CELL_REQ is sent but lost in current UE implementation!
\n
"
);
}
}
#endif
...
...
@@ -5111,6 +5112,7 @@ void *rrc_ue_task( void *args_p )
break
;
// PHY_FIND_CELL_IND
case
PHY_MEAS_REPORT_IND
:
{
LOG_D
(
RRC
,
"[UE %d] Received %s
\n
"
,
ue_mod_id
,
ITTI_MSG_NAME
(
msg_p
));
MessageDef
*
message_p
;
message_p
=
itti_alloc_new_message
(
TASK_RRC_UE
,
RRC_RAL_MEASUREMENT_REPORT_IND
);
...
...
@@ -5128,6 +5130,7 @@ void *rrc_ue_task( void *args_p )
}
case
RRC_RAL_CONFIGURE_THRESHOLD_REQ
:
LOG_D
(
RRC
,
"[UE %d] Received %s
\n
"
,
ue_mod_id
,
ITTI_MSG_NAME
(
msg_p
));
rrc_ue_ral_handle_configure_threshold_request
(
ue_mod_id
,
msg_p
);
break
;
...
...
targets/ARCH/rfsimulator/simulator.c
View file @
11fd202d
...
...
@@ -280,7 +280,7 @@ bool flushInput(tcp_bridge_state_t *t) {
else
blockSz
=
b
->
transferPtr
+
b
->
remainToTransfer
<
b
->
circularBufEnd
?
b
->
remainToTransfer
:
b
->
circularBufEnd
-
b
->
transferPtr
;
b
->
circularBufEnd
-
1
-
b
->
transferPtr
;
int
sz
=
recv
(
fd
,
b
->
transferPtr
,
blockSz
,
MSG_DONTWAIT
);
...
...
@@ -294,6 +294,8 @@ bool flushInput(tcp_bridge_state_t *t) {
AssertFatal
((
b
->
remainToTransfer
-=
sz
)
>=
0
,
""
);
b
->
transferPtr
+=
sz
;
if
(
b
->
transferPtr
==
b
->
circularBufEnd
-
1
)
b
->
transferPtr
=
(
char
*
)
b
->
circularBuf
;
// check the header and start block transfer
if
(
b
->
headerMode
==
true
&&
b
->
remainToTransfer
==
0
)
{
...
...
targets/ARCH/tcp_bridge/tcp_bridge_oai.c
View file @
11fd202d
This diff is collapsed.
Click to expand it.
targets/RT/USER/lte-ue.c
View file @
11fd202d
...
...
@@ -783,11 +783,18 @@ static void *UE_thread_rxn_txnp4(void *arg) {
threadname
);
while
(
!
oai_exit
)
{
AssertFatal
(
pthread_mutex_lock
(
&
proc
->
mutex_rxtx
)
==
0
,
"[SCHED][UE] error locking mutex for UE RXTX
\n
"
);
while
(
proc
->
instance_cnt_rxtx
<
0
)
if
(
pthread_mutex_lock
(
&
proc
->
mutex_rxtx
)
!=
0
)
{
LOG_E
(
PHY
,
"[SCHED][UE] error locking mutex for UE RXTX
\n
"
);
exit_fun
(
"nothing to add"
);
}
while
(
proc
->
instance_cnt_rxtx
<
0
)
{
// most of the time, the thread is waiting here
pthread_cond_wait
(
&
proc
->
cond_rxtx
,
&
proc
->
mutex_rxtx
);
AssertFatal
(
pthread_mutex_unlock
(
&
proc
->
mutex_rxtx
)
==
0
,
"[SCHED][UE] error unlocking mutex for UE RXn_TXnp4
\n
"
);
}
if
(
pthread_mutex_unlock
(
&
proc
->
mutex_rxtx
)
!=
0
)
{
LOG_E
(
PHY
,
"[SCHED][UE] error unlocking mutex for UE RXn_TXnp4
\n
"
);
exit_fun
(
"nothing to add"
);
}
initRefTimes
(
t2
);
initRefTimes
(
t3
);
...
...
@@ -861,12 +868,18 @@ static void *UE_thread_rxn_txnp4(void *arg) {
phy_procedures_UE_S_TX
(
UE
,
0
,
0
);
updateTimes
(
current
,
&
t3
,
10000
,
"Delay to process sub-frame (case 3)"
);
AssertFatal
(
pthread_mutex_lock
(
&
proc
->
mutex_rxtx
)
==
0
,
"[SCHED][UE] error locking mutex for UE RXTX
\n
"
);
if
(
pthread_mutex_lock
(
&
proc
->
mutex_rxtx
)
!=
0
)
{
LOG_E
(
PHY
,
"[SCHED][UE] error locking mutex for UE RXTX
\n
"
);
exit_fun
(
"noting to add"
);
}
proc
->
instance_cnt_rxtx
--
;
#if BASIC_SIMULATOR
AssertFatal
(
pthread_cond_signal
(
&
proc
->
cond_rxtx
)
==
0
,
""
);
#if
1 //
BASIC_SIMULATOR
if
(
pthread_cond_signal
(
&
proc
->
cond_rxtx
)
!=
0
)
abort
(
);
#endif
AssertFatal
(
pthread_mutex_unlock
(
&
proc
->
mutex_rxtx
)
==
0
,
"[SCHED][UE] error unlocking mutex for UE RXTX
\n
"
);
if
(
pthread_mutex_unlock
(
&
proc
->
mutex_rxtx
)
!=
0
)
{
LOG_E
(
PHY
,
"[SCHED][UE] error unlocking mutex for UE RXTX
\n
"
);
exit_fun
(
"noting to add"
);
}
}
// thread finished
...
...
@@ -981,6 +994,7 @@ static void *UE_phy_stub_single_thread_rxn_txnp4(void *arg) {
}
while
(
phy_stub_ticking
->
ticking_var
<
0
)
{
// most of the time, the thread is waiting here
//pthread_cond_wait( &proc->cond_rxtx, &proc->mutex_rxtx )
LOG_D
(
MAC
,
"Waiting for ticking_var
\n
"
);
pthread_cond_wait
(
&
phy_stub_ticking
->
cond_ticking
,
&
phy_stub_ticking
->
mutex_ticking
);
}
...
...
@@ -1265,6 +1279,7 @@ static void *UE_phy_stub_thread_rxn_txnp4(void *arg) {
}
while
(
phy_stub_ticking
->
ticking_var
<
0
)
{
// most of the time, the thread is waiting here
//pthread_cond_wait( &proc->cond_rxtx, &proc->mutex_rxtx )
LOG_D
(
MAC
,
"Waiting for ticking_var
\n
"
);
pthread_cond_wait
(
&
phy_stub_ticking
->
cond_ticking
,
&
phy_stub_ticking
->
mutex_ticking
);
}
...
...
@@ -1456,12 +1471,6 @@ void *UE_thread(void *arg) {
}
while
(
!
oai_exit
)
{
#if BASIC_SIMULATOR
while
(
!
(
UE
->
proc
.
instance_cnt_synch
<
0
))
{
printf
(
"ue sync not ready
\n
"
);
usleep
(
500
*
1000
);
}
#endif
AssertFatal
(
0
==
pthread_mutex_lock
(
&
UE
->
proc
.
mutex_synch
),
""
);
int
instance_cnt_synch
=
UE
->
proc
.
instance_cnt_synch
;
...
...
@@ -1591,7 +1600,7 @@ void *UE_thread(void *arg) {
// update thread index for received subframe
UE
->
current_thread_id
[
sub_frame
]
=
thread_idx
;
#if BASIC_SIMULATOR
#if
1 //
BASIC_SIMULATOR
{
int
t
;
for
(
t
=
0
;
t
<
2
;
t
++
)
{
...
...
@@ -1629,10 +1638,10 @@ void *UE_thread(void *arg) {
// compute TO compensation that should be applied for this frame
if
(
UE
->
no_timing_correction
==
0
)
{
if
(
getenv
(
"RFSIMULATOR"
)
!=
NULL
&&
UE
->
rx_offset
)
{
//LOG_E(HW,"in simu, rx_offset is not null (impossible)
: %d\n", UE->rx_offset);
UE
->
rx_offset
=
0
;
}
if
(
UE
->
rx_offset
)
{
//LOG_E(HW,"in simu, rx_offset is not null
: %d\n", UE->rx_offset);
UE
->
rx_offset
=
0
;
}
if
(
UE
->
rx_offset
<
5
*
UE
->
frame_parms
.
samples_per_tti
&&
UE
->
rx_offset
>
0
)
UE
->
rx_offset_diff
=
-
1
;
...
...
@@ -1704,6 +1713,7 @@ void *UE_thread(void *arg) {
proc
->
instance_cnt_rxtx
++
;
LOG_D
(
PHY
,
"[SCHED][UE %d] UE RX instance_cnt_rxtx %d subframe %d !!
\n
"
,
UE
->
Mod_id
,
proc
->
instance_cnt_rxtx
,
proc
->
subframe_rx
);
if
(
proc
->
instance_cnt_rxtx
!=
0
)
{
/*
if ( getenv("RFSIMULATOR") != NULL ) {
do {
AssertFatal (pthread_mutex_unlock(&proc->mutex_rxtx) == 0, "");
...
...
@@ -1711,7 +1721,7 @@ void *UE_thread(void *arg) {
AssertFatal (pthread_mutex_lock(&proc->mutex_rxtx) == 0, "");
} while ( proc->instance_cnt_rxtx >= 0);
}
else
} else
*/
LOG_E
(
PHY
,
"[SCHED][UE %d] UE RX thread busy (IC %d)!!
\n
"
,
UE
->
Mod_id
,
proc
->
instance_cnt_rxtx
);
if
(
proc
->
instance_cnt_rxtx
>
2
)
exit_fun
(
"instance_cnt_rxtx > 2"
);
...
...
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