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
dea85884
Commit
dea85884
authored
Jan 17, 2018
by
Eurecom
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
code cleanup
parent
cfec3ffd
Changes
5
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
139 additions
and
403 deletions
+139
-403
openair1/PHY/LTE_TRANSPORT/dlsch_coding.c
openair1/PHY/LTE_TRANSPORT/dlsch_coding.c
+97
-377
openair1/PHY/LTE_TRANSPORT/proto.h
openair1/PHY/LTE_TRANSPORT/proto.h
+2
-1
openair1/PHY/defs.h
openair1/PHY/defs.h
+14
-0
openair1/SCHED/phy_procedures_lte_eNb.c
openair1/SCHED/phy_procedures_lte_eNb.c
+19
-18
targets/RT/USER/lte-enb.c
targets/RT/USER/lte-enb.c
+7
-7
No files found.
openair1/PHY/LTE_TRANSPORT/dlsch_coding.c
View file @
dea85884
This diff is collapsed.
Click to expand it.
openair1/PHY/LTE_TRANSPORT/proto.h
View file @
dea85884
...
@@ -183,7 +183,8 @@ int32_t dlsch_encoding_2threads(PHY_VARS_eNB *eNB,
...
@@ -183,7 +183,8 @@ int32_t dlsch_encoding_2threads(PHY_VARS_eNB *eNB,
time_stats_t
*
te_main_stats
,
time_stats_t
*
te_main_stats
,
time_stats_t
*
te_wakeup_stats0
,
time_stats_t
*
te_wakeup_stats0
,
time_stats_t
*
te_wakeup_stats1
,
time_stats_t
*
te_wakeup_stats1
,
time_stats_t
*
i_stats
);
time_stats_t
*
i_stats
,
int
worker_num
);
void
dlsch_encoding_emul
(
PHY_VARS_eNB
*
phy_vars_eNB
,
void
dlsch_encoding_emul
(
PHY_VARS_eNB
*
phy_vars_eNB
,
uint8_t
*
DLSCH_pdu
,
uint8_t
*
DLSCH_pdu
,
...
...
openair1/PHY/defs.h
View file @
dea85884
...
@@ -279,6 +279,20 @@ typedef struct {
...
@@ -279,6 +279,20 @@ typedef struct {
LTE_eNB_DLSCH_t
*
dlsch
;
LTE_eNB_DLSCH_t
*
dlsch
;
int
G
;
int
G
;
int
harq_pid
;
int
harq_pid
;
int
total_worker
;
int
current_worker
;
/// \internal This variable is protected by \ref mutex_te.
int
instance_cnt_te
;
/// pthread attributes for parallel turbo-encoder thread
pthread_attr_t
attr_te
;
/// scheduling parameters for parallel turbo-encoder thread
struct
sched_param
sched_param_te
;
/// pthread structure for parallel turbo-encoder thread
pthread_t
pthread_te
;
/// condition variable for parallel turbo-encoder thread
pthread_cond_t
cond_te
;
/// mutex for parallel turbo-encoder thread
pthread_mutex_t
mutex_te
;
}
te_params
;
}
te_params
;
typedef
struct
RU_proc_t_s
{
typedef
struct
RU_proc_t_s
{
...
...
openair1/SCHED/phy_procedures_lte_eNb.c
View file @
dea85884
...
@@ -1507,41 +1507,42 @@ void init_td_thread(PHY_VARS_eNB *eNB,pthread_attr_t *attr_td) {
...
@@ -1507,41 +1507,42 @@ void init_td_thread(PHY_VARS_eNB *eNB,pthread_attr_t *attr_td) {
}
}
extern
void
*
te_thread
(
void
*
);
extern
void
*
te_thread
(
void
*
);
extern
void
*
te_thread1
(
void
*
);
extern
void
*
te_thread2
(
void
*
);
void
init_te_thread
(
PHY_VARS_eNB
*
eNB
,
pthread_attr_t
*
attr_te
,
pthread_attr_t
*
attr_te1
)
{
void
init_te_thread
(
PHY_VARS_eNB
*
eNB
)
{
eNB_proc_t
*
proc
=
&
eNB
->
proc
;
eNB_proc_t
*
proc
=
&
eNB
->
proc
;
proc
->
tep
[
0
].
eNB
=
eNB
;
proc
->
tep
[
0
].
eNB
=
eNB
;
proc
->
instance_cnt_te
[
0
]
=
-
1
;
proc
->
tep
[
0
].
instance_cnt_te
=
-
1
;
pthread_mutex_init
(
&
proc
->
mutex_te
[
0
],
NULL
);
pthread_mutex_init
(
&
proc
->
tep
[
0
].
mutex_te
,
NULL
);
pthread_cond_init
(
&
proc
->
cond_te
[
0
],
NULL
);
pthread_cond_init
(
&
proc
->
tep
[
0
].
cond_te
,
NULL
);
pthread_attr_init
(
&
proc
->
tep
[
0
].
attr_te
);
printf
(
"Creating te_thread
\n
"
);
printf
(
"Creating te_thread
0
\n
"
);
pthread_create
(
&
proc
->
pthread_te
[
0
],
attr_te
,
te_thread
,
(
void
*
)
&
proc
->
tep
[
0
]);
pthread_create
(
&
proc
->
tep
[
0
].
pthread_te
,
&
proc
->
tep
[
0
].
attr_te
,
te_thread
,
(
void
*
)
&
proc
->
tep
[
0
]);
/////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
proc
->
tep
[
1
].
eNB
=
eNB
;
proc
->
tep
[
1
].
eNB
=
eNB
;
proc
->
instance_cnt_te
[
1
]
=
-
1
;
proc
->
tep
[
1
].
instance_cnt_te
=
-
1
;
pthread_mutex_init
(
&
proc
->
mutex_te
[
1
],
NULL
);
pthread_mutex_init
(
&
proc
->
tep
[
1
].
mutex_te
,
NULL
);
pthread_cond_init
(
&
proc
->
cond_te
[
1
],
NULL
);
pthread_cond_init
(
&
proc
->
tep
[
1
].
cond_te
,
NULL
);
pthread_attr_init
(
&
proc
->
tep
[
1
].
attr_te
);
printf
(
"Creating te_thread1
\n
"
);
printf
(
"Creating te_thread
1
\n
"
);
pthread_create
(
&
proc
->
pthread_te
[
1
],
attr_te1
,
te_thread1
,
(
void
*
)
&
proc
->
tep
[
1
]);
pthread_create
(
&
proc
->
tep
[
1
].
pthread_te
,
&
proc
->
tep
[
1
].
attr_te
,
te_thread
,
(
void
*
)
&
proc
->
tep
[
1
]);
/////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////
proc
->
tep
[
2
].
eNB
=
eNB
;
proc
->
tep
[
2
].
eNB
=
eNB
;
proc
->
instance_cnt_te
[
2
]
=
-
1
;
proc
->
tep
[
2
].
instance_cnt_te
=
-
1
;
pthread_mutex_init
(
&
proc
->
mutex_te
[
2
],
NULL
);
pthread_mutex_init
(
&
proc
->
tep
[
2
].
mutex_te
,
NULL
);
pthread_cond_init
(
&
proc
->
cond_te
[
2
],
NULL
);
pthread_cond_init
(
&
proc
->
tep
[
2
].
cond_te
,
NULL
);
pthread_attr_init
(
&
proc
->
tep
[
2
].
attr_te
);
printf
(
"Creating te_thread2
\n
"
);
printf
(
"Creating te_thread
2
\n
"
);
pthread_create
(
&
proc
->
pthread_te
[
2
],
attr_te1
,
te_thread2
,
(
void
*
)
&
proc
->
tep
[
2
]);
pthread_create
(
&
proc
->
tep
[
2
].
pthread_te
,
&
proc
->
tep
[
2
].
attr_te
,
te_thread
,
(
void
*
)
&
proc
->
tep
[
2
]);
}
}
...
...
targets/RT/USER/lte-enb.c
View file @
dea85884
...
@@ -696,7 +696,7 @@ static void* eNB_thread_prach_br( void* param ) {
...
@@ -696,7 +696,7 @@ static void* eNB_thread_prach_br( void* param ) {
extern
void
init_td_thread
(
PHY_VARS_eNB
*
,
pthread_attr_t
*
);
extern
void
init_td_thread
(
PHY_VARS_eNB
*
,
pthread_attr_t
*
);
extern
void
init_te_thread
(
PHY_VARS_eNB
*
,
pthread_attr_t
*
,
pthread_attr_t
*
);
extern
void
init_te_thread
(
PHY_VARS_eNB
*
);
//////////////////////////////////////need to modified////////////////*****
//////////////////////////////////////need to modified////////////////*****
static
void
*
process_stats_thread
(
void
*
param
)
{
static
void
*
process_stats_thread
(
void
*
param
)
{
...
@@ -734,7 +734,7 @@ void init_eNB_proc(int inst) {
...
@@ -734,7 +734,7 @@ void init_eNB_proc(int inst) {
PHY_VARS_eNB
*
eNB
;
PHY_VARS_eNB
*
eNB
;
eNB_proc_t
*
proc
;
eNB_proc_t
*
proc
;
eNB_rxtx_proc_t
*
proc_rxtx
;
eNB_rxtx_proc_t
*
proc_rxtx
;
pthread_attr_t
*
attr0
=
NULL
,
*
attr1
=
NULL
,
*
attr_prach
=
NULL
,
*
attr_t
e
=
NULL
,
*
attr_te1
=
NULL
,
*
attr_td
=
NULL
;
pthread_attr_t
*
attr0
=
NULL
,
*
attr1
=
NULL
,
*
attr_prach
=
NULL
,
*
attr_t
d
=
NULL
;
//,*attr_te=NULL,*attr_te1
=NULL;
#ifdef Rel14
#ifdef Rel14
pthread_attr_t
*
attr_prach_br
=
NULL
;
pthread_attr_t
*
attr_prach_br
=
NULL
;
#endif
#endif
...
@@ -776,8 +776,8 @@ void init_eNB_proc(int inst) {
...
@@ -776,8 +776,8 @@ void init_eNB_proc(int inst) {
pthread_attr_init
(
&
proc
->
attr_prach
);
pthread_attr_init
(
&
proc
->
attr_prach
);
pthread_attr_init
(
&
proc
->
attr_asynch_rxtx
);
pthread_attr_init
(
&
proc
->
attr_asynch_rxtx
);
pthread_attr_init
(
&
proc
->
attr_td
);
pthread_attr_init
(
&
proc
->
attr_td
);
pthread_attr_init
(
&
proc
->
attr_te
[
0
]);
//
pthread_attr_init( &proc->attr_te[0]);
pthread_attr_init
(
&
proc
->
attr_te
[
1
]);
//
pthread_attr_init( &proc->attr_te[1]);
pthread_attr_init
(
&
proc_rxtx
[
0
].
attr_rxtx
);
pthread_attr_init
(
&
proc_rxtx
[
0
].
attr_rxtx
);
pthread_attr_init
(
&
proc_rxtx
[
1
].
attr_rxtx
);
pthread_attr_init
(
&
proc_rxtx
[
1
].
attr_rxtx
);
#ifdef Rel14
#ifdef Rel14
...
@@ -800,8 +800,8 @@ void init_eNB_proc(int inst) {
...
@@ -800,8 +800,8 @@ void init_eNB_proc(int inst) {
// attr_te = &proc->attr_te;
// attr_te = &proc->attr_te;
#endif
#endif
attr_td
=
&
proc
->
attr_td
;
attr_td
=
&
proc
->
attr_td
;
attr_te
=
&
proc
->
attr_te
[
0
];
//
attr_te = &proc->attr_te[0];
attr_te1
=
&
proc
->
attr_te
[
1
];
//
attr_te1 = &proc->attr_te[1];
pthread_create
(
&
proc_rxtx
[
0
].
pthread_rxtx
,
attr0
,
eNB_thread_rxtx
,
proc
);
pthread_create
(
&
proc_rxtx
[
0
].
pthread_rxtx
,
attr0
,
eNB_thread_rxtx
,
proc
);
pthread_create
(
&
proc_rxtx
[
1
].
pthread_rxtx
,
attr1
,
tx_thread
,
proc
);
pthread_create
(
&
proc_rxtx
[
1
].
pthread_rxtx
,
attr1
,
tx_thread
,
proc
);
if
(
eNB
->
single_thread_flag
==
0
)
{
if
(
eNB
->
single_thread_flag
==
0
)
{
...
@@ -824,7 +824,7 @@ void init_eNB_proc(int inst) {
...
@@ -824,7 +824,7 @@ void init_eNB_proc(int inst) {
//////////////////////////////////////need to modified////////////////*****
//////////////////////////////////////need to modified////////////////*****
init_te_thread
(
eNB
,
attr_te
,
attr_te1
);
init_te_thread
(
eNB
);
init_td_thread
(
eNB
,
attr_td
);
init_td_thread
(
eNB
,
attr_td
);
if
(
opp_enabled
==
1
)
pthread_create
(
&
proc
->
process_stats_thread
,
NULL
,
process_stats_thread
,(
void
*
)
eNB
);
if
(
opp_enabled
==
1
)
pthread_create
(
&
proc
->
process_stats_thread
,
NULL
,
process_stats_thread
,(
void
*
)
eNB
);
...
...
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