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
canghaiwuhen
OpenXG-RAN
Commits
931a2156
Commit
931a2156
authored
May 29, 2019
by
laurent
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add switch parallel/serial
parent
6925058e
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
14 deletions
+19
-14
executables/gNBmain.c
executables/gNBmain.c
+19
-14
No files found.
executables/gNBmain.c
View file @
931a2156
...
@@ -25,7 +25,7 @@
...
@@ -25,7 +25,7 @@
#include <common/utils/threadPool/thread-pool.h>
#include <common/utils/threadPool/thread-pool.h>
RAN_CONTEXT_t
RC
;
RAN_CONTEXT_t
RC
;
tpool_t
*
Tpool
;
tpool_t
*
Tpool
;
volatile
int
oai_exit
=
0
;
volatile
int
oai_exit
=
0
;
char
rf_config_file
[
1024
]
=
""
;
char
rf_config_file
[
1024
]
=
""
;
unsigned
int
mmapped_dma
=
0
;
unsigned
int
mmapped_dma
=
0
;
...
@@ -300,8 +300,10 @@ static inline int rxtx(PHY_VARS_gNB *gNB,gNB_L1_rxtx_proc_t *proc, char *thread_
...
@@ -300,8 +300,10 @@ static inline int rxtx(PHY_VARS_gNB *gNB,gNB_L1_rxtx_proc_t *proc, char *thread_
uint64_t
a
=
rdtsc
();
uint64_t
a
=
rdtsc
();
phy_procedures_gNB_TX
(
gNB
,
proc
,
1
);
phy_procedures_gNB_TX
(
gNB
,
proc
,
1
);
uint64_t
b
=
rdtsc
()
-
a
;
uint64_t
b
=
rdtsc
()
-
a
;
if
(
b
/
3500
.
0
>
100
)
if
(
b
/
3500
.
0
>
100
)
printf
(
"processin: %d, %ld
\n
"
,
proc
->
slot_rx
,
b
/
3500
);
printf
(
"processin: %d, %ld
\n
"
,
proc
->
slot_rx
,
b
/
3500
);
return
(
0
);
return
(
0
);
}
}
...
@@ -722,8 +724,9 @@ bool setup_RU_buffers(RU_t *ru) {
...
@@ -722,8 +724,9 @@ bool setup_RU_buffers(RU_t *ru) {
return
(
true
);
return
(
true
);
}
}
static
void
modulateSend
(
void
*
arg
)
{
static
void
modulateSend
(
void
*
arg
)
{
RU_t
*
ru
=*
(
RU_t
**
)
arg
;
RU_t
*
ru
=*
(
RU_t
**
)
arg
;
if
(
ru
->
num_eNB
==
0
)
{
if
(
ru
->
num_eNB
==
0
)
{
// do TX front-end processing if needed (precoding and/or IDFTs)
// do TX front-end processing if needed (precoding and/or IDFTs)
if
(
ru
->
feptx_prec
)
if
(
ru
->
feptx_prec
)
...
@@ -754,7 +757,6 @@ static void *ru_thread( void *param ) {
...
@@ -754,7 +757,6 @@ static void *ru_thread( void *param ) {
sprintf
(
threadname
,
"ru_thread %d"
,
ru
->
idx
);
sprintf
(
threadname
,
"ru_thread %d"
,
ru
->
idx
);
LOG_I
(
PHY
,
"Starting RU %d (%s,%s),
\n
"
,
ru
->
idx
,
NB_functions
[
ru
->
function
],
NB_timing
[
ru
->
if_timing
]);
LOG_I
(
PHY
,
"Starting RU %d (%s,%s),
\n
"
,
ru
->
idx
,
NB_functions
[
ru
->
function
],
NB_timing
[
ru
->
if_timing
]);
if
(
ru
->
if_south
==
LOCAL_RF
)
{
// configure RF parameters only
if
(
ru
->
if_south
==
LOCAL_RF
)
{
// configure RF parameters only
fill_rf_config
(
ru
,
ru
->
rf_config_file
);
fill_rf_config
(
ru
,
ru
->
rf_config_file
);
nr_init_frame_parms
(
&
ru
->
gNB_list
[
0
]
->
gNB_config
,
fp
);
nr_init_frame_parms
(
&
ru
->
gNB_list
[
0
]
->
gNB_config
,
fp
);
...
@@ -850,10 +852,14 @@ static void *ru_thread( void *param ) {
...
@@ -850,10 +852,14 @@ static void *ru_thread( void *param ) {
updateTimes
(
beg3
,
&
mainProc
,
1000
,
"rxtx"
);
updateTimes
(
beg3
,
&
mainProc
,
1000
,
"rxtx"
);
if
(
0
)
{
notifiedFIFO_elt_t
*
txWork
=
newNotifiedFIFO_elt
(
0
,
0
,
NULL
,
modulateSend
);
notifiedFIFO_elt_t
*
txWork
=
newNotifiedFIFO_elt
(
0
,
0
,
NULL
,
modulateSend
);
void
**
tmp
=
(
void
**
)
NotifiedFifoData
(
txWork
);
void
**
tmp
=
(
void
**
)
NotifiedFifoData
(
txWork
);
*
tmp
=
(
void
*
)
ru
;
*
tmp
=
(
void
*
)
ru
;
pushTpool
(
Tpool
,
txWork
);
pushTpool
(
Tpool
,
txWork
);
}
else
{
modulateSend
(
&
ru
);
}
}
}
notifiedFIFO_elt_t
*
msg2
=
newNotifiedFIFO_elt
(
sizeof
(
ru
),
AbortRU
,
NULL
,
modulateSend
);
notifiedFIFO_elt_t
*
msg2
=
newNotifiedFIFO_elt
(
sizeof
(
ru
),
AbortRU
,
NULL
,
modulateSend
);
...
@@ -1316,7 +1322,6 @@ int main( int argc, char **argv ) {
...
@@ -1316,7 +1322,6 @@ int main( int argc, char **argv ) {
memset
(
&
UE_PF_PO
[
0
][
0
],
0
,
sizeof
(
UE_PF_PO_t
)
*
NUMBER_OF_UE_MAX
*
MAX_NUM_CCs
);
memset
(
&
UE_PF_PO
[
0
][
0
],
0
,
sizeof
(
UE_PF_PO_t
)
*
NUMBER_OF_UE_MAX
*
MAX_NUM_CCs
);
pthread_cond_init
(
&
sync_cond
,
NULL
);
pthread_cond_init
(
&
sync_cond
,
NULL
);
pthread_mutex_init
(
&
sync_mutex
,
NULL
);
pthread_mutex_init
(
&
sync_mutex
,
NULL
);
tpool_t
pool
;
tpool_t
pool
;
Tpool
=&
pool
;
Tpool
=&
pool
;
char
params
[]
=
"-1,-1"
;
char
params
[]
=
"-1,-1"
;
...
...
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