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
ba400d56
Commit
ba400d56
authored
Apr 05, 2018
by
Robert Schmidt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
reorganize TASK_L2L1 loop
parent
a112f2ad
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
50 deletions
+14
-50
targets/RT/USER/lte-softmodem.c
targets/RT/USER/lte-softmodem.c
+14
-50
No files found.
targets/RT/USER/lte-softmodem.c
View file @
ba400d56
...
@@ -444,61 +444,25 @@ void *l2l1_task(void *arg) {
...
@@ -444,61 +444,25 @@ void *l2l1_task(void *arg) {
itti_set_task_real_time
(
TASK_L2L1
);
itti_set_task_real_time
(
TASK_L2L1
);
itti_mark_task_ready
(
TASK_L2L1
);
itti_mark_task_ready
(
TASK_L2L1
);
/* Wait for the initialize message */
/* Wait for the initialize message */
printf
(
"Wait for the ITTI initialize message
\n
"
);
printf
(
"Wait for the ITTI initialize message
\n
"
);
do
{
while
(
1
)
{
if
(
message_p
!=
NULL
)
{
result
=
itti_free
(
ITTI_MSG_ORIGIN_ID
(
message_p
),
message_p
);
AssertFatal
(
result
==
EXIT_SUCCESS
,
"Failed to free memory (%d)!
\n
"
,
result
);
}
itti_receive_msg
(
TASK_L2L1
,
&
message_p
);
switch
(
ITTI_MSG_ID
(
message_p
))
{
case
INITIALIZE_MESSAGE
:
/* Start eNB thread */
LOG_D
(
EMU
,
"L2L1 TASK received %s
\n
"
,
ITTI_MSG_NAME
(
message_p
));
start_eNB
=
1
;
break
;
case
TERMINATE_MESSAGE
:
LOG_W
(
EMU
,
" *** Exiting L2L1 thread
\n
"
);
oai_exit
=
1
;
start_eNB
=
0
;
itti_exit_task
();
break
;
default:
LOG_E
(
EMU
,
"Received unexpected message %s
\n
"
,
ITTI_MSG_NAME
(
message_p
));
break
;
}
}
while
(
ITTI_MSG_ID
(
message_p
)
!=
INITIALIZE_MESSAGE
);
result
=
itti_free
(
ITTI_MSG_ORIGIN_ID
(
message_p
),
message_p
);
AssertFatal
(
result
==
EXIT_SUCCESS
,
"Failed to free memory (%d)!
\n
"
,
result
);
/* ???? no else but seems to be UE only ???
do {
// Wait for a message
itti_receive_msg
(
TASK_L2L1
,
&
message_p
);
itti_receive_msg
(
TASK_L2L1
,
&
message_p
);
switch
(
ITTI_MSG_ID
(
message_p
))
{
switch
(
ITTI_MSG_ID
(
message_p
))
{
case
INITIALIZE_MESSAGE
:
/* Start eNB thread */
LOG_D
(
EMU
,
"L2L1 TASK received %s
\n
"
,
ITTI_MSG_NAME
(
message_p
));
start_eNB
=
1
;
break
;
case
TERMINATE_MESSAGE
:
case
TERMINATE_MESSAGE
:
LOG_W
(
EMU
,
" *** Exiting L2L1 thread
\n
"
);
oai_exit
=
1
;
oai_exit
=
1
;
start_eNB
=
0
;
itti_exit_task
();
itti_exit_task
();
break
;
break
;
case ACTIVATE_MESSAGE:
start_UE = 1;
break;
case DEACTIVATE_MESSAGE:
start_UE = 0;
break;
case MESSAGE_TEST:
LOG_I(EMU, "Received %s\n", ITTI_MSG_NAME(message_p));
break;
default:
default:
LOG_E
(
EMU
,
"Received unexpected message %s
\n
"
,
ITTI_MSG_NAME
(
message_p
));
LOG_E
(
EMU
,
"Received unexpected message %s
\n
"
,
ITTI_MSG_NAME
(
message_p
));
break
;
break
;
...
@@ -506,8 +470,9 @@ void *l2l1_task(void *arg) {
...
@@ -506,8 +470,9 @@ void *l2l1_task(void *arg) {
result
=
itti_free
(
ITTI_MSG_ORIGIN_ID
(
message_p
),
message_p
);
result
=
itti_free
(
ITTI_MSG_ORIGIN_ID
(
message_p
),
message_p
);
AssertFatal
(
result
==
EXIT_SUCCESS
,
"Failed to free memory (%d)!
\n
"
,
result
);
AssertFatal
(
result
==
EXIT_SUCCESS
,
"Failed to free memory (%d)!
\n
"
,
result
);
} while(!oai_exit);
message_p
=
NULL
;
*/
};
return
NULL
;
return
NULL
;
}
}
#endif
#endif
...
@@ -796,7 +761,6 @@ extern void phy_free_RU(RU_t*);
...
@@ -796,7 +761,6 @@ extern void phy_free_RU(RU_t*);
int
stop_L1L2
(
module_id_t
enb_id
)
int
stop_L1L2
(
module_id_t
enb_id
)
{
{
LOG_W
(
ENB_APP
,
"stopping lte-softmodem
\n
"
);
LOG_W
(
ENB_APP
,
"stopping lte-softmodem
\n
"
);
oai_exit
=
1
;
if
(
!
RC
.
ru
)
{
if
(
!
RC
.
ru
)
{
LOG_F
(
ENB_APP
,
"no RU configured
\n
"
);
LOG_F
(
ENB_APP
,
"no RU configured
\n
"
);
...
...
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