Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
OAI-RAN-5G-sheduler_MaxTBS
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
MAQ5G-PFC
OAI-RAN-5G-sheduler_MaxTBS
Commits
4c069754
Commit
4c069754
authored
6 years ago
by
Cedric Roux
Browse files
Options
Downloads
Plain Diff
Merge remote-tracking branch 'origin/basic-simulator-fixes' into develop_integration_2018_w35
parents
c22180ff
a48c3658
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
openair1/PHY/LTE_TRANSPORT/dci.c
+8
-0
8 additions, 0 deletions
openair1/PHY/LTE_TRANSPORT/dci.c
targets/ARCH/tcp_bridge/tcp_bridge_oai.c
+1
-1
1 addition, 1 deletion
targets/ARCH/tcp_bridge/tcp_bridge_oai.c
targets/RT/USER/lte-ue.c
+15
-19
15 additions, 19 deletions
targets/RT/USER/lte-ue.c
with
24 additions
and
20 deletions
openair1/PHY/LTE_TRANSPORT/dci.c
+
8
−
0
View file @
4c069754
...
...
@@ -346,6 +346,13 @@ uint8_t generate_dci_top(uint8_t num_pdcch_symbols,
y
[
0
]
=
&
yseq0
[
0
];
y
[
1
]
=
&
yseq1
[
0
];
#if BASIC_SIMULATOR
/* this should be the normal case
* but it has to be validated for all the various cases
* so let's just do it for the basic simulator
*/
memset
(
e
,
2
,
DCI_BITS_MAX
);
#else
#if 1
// reset all bits to <NIL>, here we set <NIL> elements as 2
// memset(e, 2, DCI_BITS_MAX);
...
...
@@ -358,6 +365,7 @@ uint8_t generate_dci_top(uint8_t num_pdcch_symbols,
* (not sure about this, to be checked somehow)
*/
//memset(e, 0, DCI_BITS_MAX);
#endif
/* BASIC_SIMULATOR */
e_ptr
=
e
;
...
...
This diff is collapsed.
Click to expand it.
targets/ARCH/tcp_bridge/tcp_bridge_oai.c
+
1
−
1
View file @
4c069754
...
...
@@ -253,7 +253,7 @@ int tcp_bridge_ue_first_read(openair0_device *device, openair0_timestamp *timest
tcp_bridge_state_t
*
t
=
device
->
priv
;
uint32_t
b
[
t
->
samples_per_subframe
*
12
];
memset
(
b
,
0
,
n
samp
s
*
4
);
memset
(
b
,
0
,
t
->
samp
les_per_subframe
*
12
*
4
);
int
n
=
fullwrite
(
t
->
sock
,
b
,
t
->
samples_per_subframe
*
12
*
4
);
if
(
n
!=
t
->
samples_per_subframe
*
12
*
4
)
{
printf
(
"tcp_bridge: write error ret %d error %s
\n
"
,
n
,
strerror
(
errno
));
...
...
This diff is collapsed.
Click to expand it.
targets/RT/USER/lte-ue.c
+
15
−
19
View file @
4c069754
...
...
@@ -446,7 +446,6 @@ static void *UE_thread_synch(void *arg)
int
freq_offset
=
0
;
char
threadname
[
128
];
UE
->
is_synchronized
=
0
;
printf
(
"UE_thread_sync in with PHY_vars_UE %p
\n
"
,
arg
);
cpu_set_t
cpuset
;
...
...
@@ -522,11 +521,6 @@ static void *UE_thread_synch(void *arg)
printf
(
"Started device, unlocked sync_mutex (UE_sync_thread)
\n
"
);
if
(
UE
->
rfdevice
.
trx_start_func
(
&
UE
->
rfdevice
)
!=
0
)
{
LOG_E
(
HW
,
"Could not start the device
\n
"
);
oai_exit
=
1
;
}
while
(
oai_exit
==
0
)
{
AssertFatal
(
0
==
pthread_mutex_lock
(
&
UE
->
proc
.
mutex_synch
),
""
);
while
(
UE
->
proc
.
instance_cnt_synch
<
0
)
...
...
@@ -755,7 +749,6 @@ static void *UE_thread_rxn_txnp4(void *arg) {
UE_rxtx_proc_t
*
proc
=
rtd
->
proc
;
PHY_VARS_UE
*
UE
=
rtd
->
UE
;
proc
->
instance_cnt_rxtx
=-
1
;
proc
->
subframe_rx
=
proc
->
sub_frame_start
;
char
threadname
[
256
];
...
...
@@ -1457,20 +1450,25 @@ void *UE_thread(void *arg) {
int
sub_frame
=-
1
;
//int cumulated_shift=0;
if
(
UE
->
rfdevice
.
trx_start_func
(
&
UE
->
rfdevice
)
!=
0
)
{
LOG_E
(
HW
,
"Could not start the device
\n
"
);
oai_exit
=
1
;
}
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
;
int
is_synchronized
=
UE
->
is_synchronized
;
AssertFatal
(
0
==
pthread_mutex_unlock
(
&
UE
->
proc
.
mutex_synch
),
""
);
if
(
is_synchronized
==
0
)
{
#if BASIC_SIMULATOR
while
(
!
((
instance_cnt_synch
=
UE
->
proc
.
instance_cnt_synch
)
<
0
))
{
printf
(
"ue sync not ready
\n
"
);
usleep
(
500
*
1000
);
}
#endif
if
(
instance_cnt_synch
<
0
)
{
// we can invoke the synch
// grab 10 ms of signal and wakeup synch thread
for
(
int
i
=
0
;
i
<
UE
->
frame_parms
.
nb_antennas_rx
;
i
++
)
...
...
@@ -1661,12 +1659,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
(
pthread_cond_signal
(
&
proc
->
cond_rxtx
)
!=
0
)
{
LOG_E
(
PHY
,
"[SCHED][UE %d] ERROR pthread_cond_signal for UE RX thread
\n
"
,
UE
->
Mod_id
);
exit_fun
(
"nothing to add"
);
}
}
else
{
if
(
proc
->
instance_cnt_rxtx
!=
0
)
{
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"
);
...
...
@@ -1717,6 +1710,8 @@ void init_UE_threads(int inst) {
pthread_mutex_init
(
&
UE
->
proc
.
mutex_synch
,
NULL
);
pthread_cond_init
(
&
UE
->
proc
.
cond_synch
,
NULL
);
UE
->
proc
.
instance_cnt_synch
=
-
1
;
UE
->
is_synchronized
=
0
;
// the threads are not yet active, therefore access is allowed without locking
int
nb_threads
=
RX_NB_TH
;
...
...
@@ -1728,6 +1723,7 @@ void init_UE_threads(int inst) {
pthread_mutex_init
(
&
UE
->
proc
.
proc_rxtx
[
i
].
mutex_rxtx
,
NULL
);
pthread_cond_init
(
&
UE
->
proc
.
proc_rxtx
[
i
].
cond_rxtx
,
NULL
);
UE
->
proc
.
proc_rxtx
[
i
].
instance_cnt_rxtx
=
-
1
;
UE
->
proc
.
proc_rxtx
[
i
].
sub_frame_start
=
i
;
UE
->
proc
.
proc_rxtx
[
i
].
sub_frame_step
=
nb_threads
;
printf
(
"Init_UE_threads rtd %d proc %d nb_threads %d i %d
\n
"
,
rtd
->
proc
->
sub_frame_start
,
UE
->
proc
.
proc_rxtx
[
i
].
sub_frame_start
,
nb_threads
,
i
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment