Fix issues with RLF in B210 and X300 (#669)

* Calling tx_end() from radio_reset() causes long execution time in B210. Using boolean to call later instead. Fixes RLF failing in B210. Checked in X300

* Fix issue #655
master
Ismael Gomez 5 years ago committed by GitHub
parent a2ab043c0d
commit 0984debe1b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -408,38 +408,51 @@ struct mac_cfg_t {
**************************/ **************************/
struct phy_cfg_t { struct phy_cfg_t {
phy_cfg_t() phy_cfg_t() { set_defaults(); }
void set_defaults()
{ {
ZERO_OBJECT(ul_cfg); ZERO_OBJECT(ul_cfg);
ZERO_OBJECT(dl_cfg); ZERO_OBJECT(dl_cfg);
ZERO_OBJECT(prach_cfg); ZERO_OBJECT(prach_cfg);
set_defaults_common(); // CommonConfig defaults for non-zero values
set_defaults_dedicated();
}
void set_defaults_common()
{
ul_cfg.pucch.delta_pucch_shift = 1; ul_cfg.pucch.delta_pucch_shift = 1;
ul_cfg.power_ctrl.delta_f_pucch[0] = 0; ul_cfg.power_ctrl.delta_f_pucch[0] = 0;
ul_cfg.power_ctrl.delta_f_pucch[1] = 1; ul_cfg.power_ctrl.delta_f_pucch[1] = 1;
ul_cfg.power_ctrl.delta_f_pucch[2] = 0; ul_cfg.power_ctrl.delta_f_pucch[2] = 0;
ul_cfg.power_ctrl.delta_f_pucch[3] = 0; ul_cfg.power_ctrl.delta_f_pucch[3] = 0;
ul_cfg.power_ctrl.delta_f_pucch[4] = 0; ul_cfg.power_ctrl.delta_f_pucch[4] = 0;
set_defaults_dedicated();
} }
// 36.331 9.2.4
void set_defaults_dedicated() void set_defaults_dedicated()
{ {
dl_cfg.tm = SRSLTE_TM1; dl_cfg.tm = SRSLTE_TM1;
dl_cfg.pdsch.use_tbs_index_alt = false;
dl_cfg.pdsch.p_a = 0;
dl_cfg.cqi_report.periodic_configured = false;
dl_cfg.cqi_report.aperiodic_configured = false;
ul_cfg.pucch.tdd_ack_multiplex = false;
ul_cfg.pusch.uci_offset.I_offset_ack = 10; ul_cfg.pusch.uci_offset.I_offset_ack = 10;
ul_cfg.pusch.uci_offset.I_offset_cqi = 15;
ul_cfg.pusch.uci_offset.I_offset_ri = 12; ul_cfg.pusch.uci_offset.I_offset_ri = 12;
ul_cfg.pusch.uci_offset.I_offset_cqi = 15;
ul_cfg.power_ctrl.p0_nominal_pusch = 0;
ul_cfg.power_ctrl.delta_mcs_based = false;
ul_cfg.power_ctrl.acc_enabled = true; ul_cfg.power_ctrl.acc_enabled = true;
ul_cfg.power_ctrl.p0_nominal_pucch = 0;
ul_cfg.power_ctrl.p_srs_offset = 7; ul_cfg.power_ctrl.p_srs_offset = 7;
// Rest of default values are 0 or false ul_cfg.srs.dedicated_enabled = false;
ul_cfg.pucch.sr_configured = false;
} }
srslte_dl_cfg_t dl_cfg; srslte_dl_cfg_t dl_cfg;

@ -177,6 +177,8 @@ private:
uint32_t nof_workers; uint32_t nof_workers;
uint32_t max_workers; uint32_t max_workers;
bool is_pending_tx_end = false;
srslte::radio_interface_phy* radio_h; srslte::radio_interface_phy* radio_h;
float cfo; float cfo;
srslte::log* log_h; srslte::log* log_h;

@ -584,6 +584,10 @@ void phy_common::worker_end(uint32_t tti,
radio_h->tx(i, buffer[i], nof_samples[i], tx_time[i]); radio_h->tx(i, buffer[i], nof_samples[i], tx_time[i]);
} else { } else {
if (radio_h->is_continuous_tx()) { if (radio_h->is_continuous_tx()) {
if (is_pending_tx_end) {
radio_h->tx_end();
is_pending_tx_end = false;
} else {
if (!radio_h->get_is_start_of_burst(i)) { if (!radio_h->get_is_start_of_burst(i)) {
if (ul_channel && !srslte_timestamp_iszero(&tx_time[i])) { if (ul_channel && !srslte_timestamp_iszero(&tx_time[i])) {
@ -593,11 +597,14 @@ void phy_common::worker_end(uint32_t tti,
radio_h->tx(i, zeros_multi, nof_samples[i], tx_time[i]); radio_h->tx(i, zeros_multi, nof_samples[i], tx_time[i]);
} }
}
} else { } else {
if (i == 0) {
radio_h->tx_end(); radio_h->tx_end();
} }
} }
} }
}
// Allow next TTI to transmit // Allow next TTI to transmit
sem_post(&tx_sem[(tti + 1) % nof_workers]); sem_post(&tx_sem[(tti + 1) % nof_workers]);
@ -696,9 +703,7 @@ void phy_common::reset_radio()
// Since is_first_of_burst is set to true, the radio need to send // Since is_first_of_burst is set to true, the radio need to send
// end of burst in order to stall correctly the Tx stream. // end of burst in order to stall correctly the Tx stream.
// This is required for UHD version 3.10 and newer. // This is required for UHD version 3.10 and newer.
if (radio_h) { is_pending_tx_end = true;
radio_h->tx_end();
}
} }
void phy_common::reset() void phy_common::reset()

@ -1340,8 +1340,8 @@ void rrc::leave_connected()
nas->leave_connected(); nas->leave_connected();
pdcp->reset(); pdcp->reset();
rlc->reset(); rlc->reset();
phy->reset();
mac->reset(); mac->reset();
phy->reset();
set_phy_default(); set_phy_default();
set_mac_default(); set_mac_default();
stop_timers(); stop_timers();
@ -2421,8 +2421,7 @@ void rrc::log_phy_config_dedicated()
// Apply default physical common and dedicated configuration // Apply default physical common and dedicated configuration
void rrc::set_phy_default() void rrc::set_phy_default()
{ {
current_phy_cfg.set_defaults_dedicated(); current_phy_cfg.set_defaults();
current_phy_cfg.set_defaults_common();
if (phy != nullptr) { if (phy != nullptr) {
phy->set_config(current_phy_cfg); phy->set_config(current_phy_cfg);

Loading…
Cancel
Save