From a5cffd8240d9af5a2f1946143bc1e7302dcf392c Mon Sep 17 00:00:00 2001 From: WANG Tsu-Han <wangts@eurecom.fr> Date: Tue, 26 May 2020 16:21:20 +0200 Subject: [PATCH] device funtion call initalization fix --- executables/nr-ru.c | 11 ++++++++++- .../CONF/gnb.band78.tm1.106PRB.usrpn300.conf | 2 +- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/executables/nr-ru.c b/executables/nr-ru.c index 7837f374098..f3c1e15efe7 100644 --- a/executables/nr-ru.c +++ b/executables/nr-ru.c @@ -1465,7 +1465,14 @@ void *ru_thread( void *param ) { if ((ru->is_slave) && (ru->if_south == LOCAL_RF)) do_ru_synch(ru); // start trx write thread - ru->start_write_thread(ru); + if (ru->start_write_thread){ + if(ru->start_write_thread(ru) != 0){ + LOG_E(HW,"Could not start tx write thread\n"); + } + else{ + LOG_I(PHY,"tx write thread ready\n"); + } + } } pthread_mutex_lock(&proc->mutex_FH1); @@ -2099,6 +2106,7 @@ void set_function_spec_param(RU_t *ru) { ru->fh_south_asynch_in = NULL; // no asynchronous UL ru->start_rf = NULL; // no local RF ru->stop_rf = NULL; + ru->start_write_thread = NULL; ru->nr_start_if = nr_start_if; // need to start if interface for IF5 ru->ifdevice.host_type = RAU_HOST; ru->ifdevice.eth_params = &ru->eth_params; @@ -2125,6 +2133,7 @@ void set_function_spec_param(RU_t *ru) { ru->fh_north_asynch_in = NULL; ru->start_rf = NULL; // no local RF ru->stop_rf = NULL; + ru->start_write_thread = NULL; ru->nr_start_if = nr_start_if; // need to start if interface for IF4p5 ru->ifdevice.host_type = RAU_HOST; ru->ifdevice.eth_params = &ru->eth_params; diff --git a/targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpn300.conf b/targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpn300.conf index 0d66385dcfc..fed15739cf5 100644 --- a/targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpn300.conf +++ b/targets/PROJECTS/GENERIC-LTE-EPC/CONF/gnb.band78.tm1.106PRB.usrpn300.conf @@ -238,7 +238,7 @@ RUs = ( max_rxgain = 114; eNB_instances = [0]; sdr_addrs = "addr=192.168.10.2,mgmt_addr=192.168.10.2,second_addr=192.168.20.2"; - clock_src = "internal"; + clock_src = "external"; } ); -- GitLab