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
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
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
OpenXG-RAN
Commits
b2583c6f
Commit
b2583c6f
authored
Sep 06, 2018
by
Raymond Knopp
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
CU is exectuable
parent
32a39e9a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
154 additions
and
115 deletions
+154
-115
targets/RT/USER/lte-softmodem.c
targets/RT/USER/lte-softmodem.c
+154
-115
No files found.
targets/RT/USER/lte-softmodem.c
View file @
b2583c6f
...
...
@@ -986,6 +986,7 @@ int main( int argc, char **argv )
LOG_E
(
OPT
,
"failed to run OPT
\n
"
);
}
if
(
RC
.
rrc
[
0
]
->
node_type
!=
ngran_eNB_DU
)
{
#ifdef PDCP_USE_NETLINK
printf
(
"PDCP netlink
\n
"
);
netlink_init
();
...
...
@@ -993,6 +994,7 @@ int main( int argc, char **argv )
pdcp_netlink_init
();
#endif
#endif
}
#if !defined(ENABLE_ITTI)
// to make a graceful exit when ctrl-c is pressed
...
...
@@ -1059,7 +1061,8 @@ int main( int argc, char **argv )
#if defined(ENABLE_ITTI)
int
have_rrc
=
0
;
if
(
RC
.
nb_inst
>
0
)
{
// don't create if node doesn't connect to RRC/S1/F1/GTP
...
...
@@ -1068,12 +1071,13 @@ int main( int argc, char **argv )
exit
(
-
1
);
// need a softer mode
}
printf
(
"ITTI tasks created
\n
"
);
have_rrc
=
1
;
}
else
{
printf
(
"No ITTI, Initializing L1
\n
"
);
RCconfig_L1
();
}
#endif
/* Start the agent. If it is turned off in the configuration, it won't start */
RCconfig_flexran
();
...
...
@@ -1081,6 +1085,32 @@ int main( int argc, char **argv )
flexran_agent_start
(
i
);
}
int
cu_flag
=
0
;
if
(
have_rrc
==
1
)
{
// wait for RRC to be initialized
int
rrc_allocated
;
do
{
rrc_allocated
=
1
;
for
(
int
i
=
0
;
i
<
RC
.
nb_inst
;
i
++
)
if
(
RC
.
rrc
==
NULL
||
RC
.
rrc
[
i
]
==
NULL
)
rrc_allocated
=
0
;
if
(
rrc_allocated
==
0
)
{
printf
(
"Waiting for RRC allocation ...
\n
"
);
usleep
(
10000
);
}
}
while
(
rrc_allocated
==
0
);
int
cell_info_configured
;
do
{
pthread_mutex_lock
(
&
RC
.
rrc
[
0
]
->
cell_info_mutex
);
cell_info_configured
=
RC
.
rrc
[
0
]
->
cell_info_configured
;
pthread_mutex_unlock
(
&
RC
.
rrc
[
0
]
->
cell_info_mutex
);
if
(
cell_info_configured
==
0
)
{
printf
(
"Waiting for RRC cell configuration
\n
"
);
usleep
(
10000
);}
}
while
(
cell_info_configured
==
0
);
if
(
RC
.
rrc
[
0
]
->
node_type
==
ngran_eNB_CU
||
RC
.
rrc
[
0
]
->
node_type
==
ngran_ng_eNB_CU
)
cu_flag
=
1
;
}
if
(
cu_flag
==
0
)
{
// init UE_PF_PO and mutex lock
pthread_mutex_init
(
&
ue_pf_po_mutex
,
NULL
);
memset
(
&
UE_PF_PO
[
0
][
0
],
0
,
sizeof
(
UE_PF_PO_t
)
*
MAX_MOBILES_PER_ENB
*
MAX_NUM_CCs
);
...
...
@@ -1159,6 +1189,7 @@ int main( int argc, char **argv )
if
(
nfapi_mode
==
2
)
// VNF
wait_nfapi_init
(
"main?"
);
printf
(
"START MAIN THREADS
\n
"
);
// start the main threads
...
...
@@ -1221,6 +1252,7 @@ int main( int argc, char **argv )
sync_var
=
0
;
pthread_cond_broadcast
(
&
sync_cond
);
pthread_mutex_unlock
(
&
sync_mutex
);
}
// wait for end of program
printf
(
"TYPE <CTRL-C> TO TERMINATE
\n
"
);
...
...
@@ -1241,6 +1273,10 @@ int main( int argc, char **argv )
#endif
// stop threads
if
(
cu_flag
==
0
)
{
int
UE_id
;
#ifdef XFORMS
printf
(
"waiting for XFORMS thread
\n
"
);
...
...
@@ -1284,9 +1320,6 @@ int main( int argc, char **argv )
}
free_lte_top
();
printf
(
"About to call end_configmodule() from %s() %s:%d
\n
"
,
__FUNCTION__
,
__FILE__
,
__LINE__
);
end_configmodule
();
printf
(
"Called end_configmodule() from %s() %s:%d
\n
"
,
__FUNCTION__
,
__FILE__
,
__LINE__
);
pthread_cond_destroy
(
&
sync_cond
);
pthread_mutex_destroy
(
&
sync_mutex
);
...
...
@@ -1309,6 +1342,12 @@ int main( int argc, char **argv )
RC
.
ru
[
ru_id
]
->
ifdevice
.
trx_end_func
=
NULL
;
}
}
}
printf
(
"About to call end_configmodule() from %s() %s:%d
\n
"
,
__FUNCTION__
,
__FILE__
,
__LINE__
);
end_configmodule
();
printf
(
"Called end_configmodule() from %s() %s:%d
\n
"
,
__FUNCTION__
,
__FILE__
,
__LINE__
);
if
(
opt_enabled
==
1
)
terminate_opt
();
...
...
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