diff --git a/srsue/hdr/upper/rrc.h b/srsue/hdr/upper/rrc.h index 1a965c3cf..62a25b1ee 100644 --- a/srsue/hdr/upper/rrc.h +++ b/srsue/hdr/upper/rrc.h @@ -623,6 +623,7 @@ private: void rrc_connection_release(); void radio_link_failure(); void leave_connected(); + void stop_timers(); void apply_rr_config_common_dl(LIBLTE_RRC_RR_CONFIG_COMMON_STRUCT *config); void apply_rr_config_common_ul(LIBLTE_RRC_RR_CONFIG_COMMON_STRUCT *config); diff --git a/srsue/src/upper/rrc.cc b/srsue/src/upper/rrc.cc index 7a23f956a..9cf41cb1d 100644 --- a/srsue/src/upper/rrc.cc +++ b/srsue/src/upper/rrc.cc @@ -219,6 +219,7 @@ void rrc::init(phy_interface_rrc *phy_, void rrc::stop() { running = false; + stop_timers(); cmd_msg_t msg; msg.command = cmd_msg_t::STOP; cmd_q.push(msg); @@ -1655,10 +1656,7 @@ void rrc::leave_connected() mac->reset(); set_phy_default(); set_mac_default(); - mac_timers->timer_get(t301)->stop(); - mac_timers->timer_get(t310)->stop(); - mac_timers->timer_get(t311)->stop(); - mac_timers->timer_get(t304)->stop(); + stop_timers(); rrc_log->info("Going RRC_IDLE\n"); if (phy->cell_is_camping()) { // Receive paging @@ -1668,10 +1666,14 @@ void rrc::leave_connected() } } - - - - +void rrc::stop_timers() +{ + mac_timers->timer_get(t300)->stop(); + mac_timers->timer_get(t301)->stop(); + mac_timers->timer_get(t310)->stop(); + mac_timers->timer_get(t311)->stop(); + mac_timers->timer_get(t304)->stop(); +} /******************************************************************************* *