From fca1273b3e02a7d8dcd121915f8da6833c4a2a09 Mon Sep 17 00:00:00 2001 From: Francisco Paisana Date: Thu, 27 Aug 2020 18:47:12 +0100 Subject: [PATCH] avoid spurious warnings of trying to start the PRACH when it is already running during handover --- srsue/hdr/stack/mac/proc_ra.h | 2 ++ srsue/src/stack/mac/proc_sr.cc | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/srsue/hdr/stack/mac/proc_ra.h b/srsue/hdr/stack/mac/proc_ra.h index df1670e7f..12130e828 100644 --- a/srsue/hdr/stack/mac/proc_ra.h +++ b/srsue/hdr/stack/mac/proc_ra.h @@ -98,6 +98,8 @@ public: void notify_phy_config_completed(uint32_t task_id); void notify_ra_completed(uint32_t task_id); + bool is_idle() const { return state == IDLE; } + private: void state_pdcch_setup(); void state_response_reception(uint32_t tti); diff --git a/srsue/src/stack/mac/proc_sr.cc b/srsue/src/stack/mac/proc_sr.cc index 5b8845b6d..dfb206792 100644 --- a/srsue/src/stack/mac/proc_sr.cc +++ b/srsue/src/stack/mac/proc_sr.cc @@ -95,7 +95,7 @@ void sr_proc::step(uint32_t tti) reset(); } } - } else { + } else if (ra->is_idle()) { Info("SR: PUCCH not configured. Starting RA procedure\n"); ra->start_mac_order(); reset();