From 88461646ac7c97af9571e16dd0a3ea058fb947d0 Mon Sep 17 00:00:00 2001 From: Francisco Date: Tue, 7 Dec 2021 01:09:32 +0000 Subject: [PATCH] nr,gnb,sched: fix failing sched unit test --- srsgnb/src/stack/mac/sched_nr_grant_allocator.cc | 6 ++---- srsgnb/src/stack/mac/test/sched_nr_parallel_test.cc | 1 + 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/srsgnb/src/stack/mac/sched_nr_grant_allocator.cc b/srsgnb/src/stack/mac/sched_nr_grant_allocator.cc index 137855ce7..ad1aff562 100644 --- a/srsgnb/src/stack/mac/sched_nr_grant_allocator.cc +++ b/srsgnb/src/stack/mac/sched_nr_grant_allocator.cc @@ -311,8 +311,7 @@ alloc_result bwp_slot_allocator::alloc_pdsch(slot_ue& ue, prb_grant dl_grant) // TODO // Choose SearchSpace + DCI format - srsran_rnti_type_t rnti_type = - ue->ue_cfg().ue_bearers[1].direction == mac_lc_ch_cfg_t::IDLE ? srsran_rnti_type_tc : srsran_rnti_type_c; + srsran_rnti_type_t rnti_type = srsran_rnti_type_c; // Choose the ss_id the highest number of candidates candidate_ss_list_t ss_candidates = find_ss(ue->phy().pdcch, aggr_idx, rnti_type, dci_fmt_list); if (ss_candidates.empty()) { @@ -420,8 +419,7 @@ alloc_result bwp_slot_allocator::alloc_pusch(slot_ue& ue, prb_grant ul_grant) } // Choose SearchSpace + DCI format - srsran_rnti_type_t rnti_type = - ue->ue_cfg().ue_bearers[1].direction == mac_lc_ch_cfg_t::IDLE ? srsran_rnti_type_tc : srsran_rnti_type_c; + srsran_rnti_type_t rnti_type = srsran_rnti_type_c; candidate_ss_list_t ss_candidates = find_ss(ue->phy().pdcch, aggr_idx, rnti_type, dci_fmt_list); if (ss_candidates.empty()) { // Could not find space in PDCCH diff --git a/srsgnb/src/stack/mac/test/sched_nr_parallel_test.cc b/srsgnb/src/stack/mac/test/sched_nr_parallel_test.cc index 900958411..12f0e721b 100644 --- a/srsgnb/src/stack/mac/test/sched_nr_parallel_test.cc +++ b/srsgnb/src/stack/mac/test/sched_nr_parallel_test.cc @@ -86,6 +86,7 @@ void run_sched_nr_test(uint32_t nof_workers) slot_point slot_tx = slot_rx + TX_ENB_DELAY; if (slot_rx.to_uint() == 9) { sched_nr_interface::ue_cfg_t uecfg = get_default_ue_cfg(nof_sectors); + uecfg.ue_bearers[1].direction = mac_lc_ch_cfg_t::BOTH; tester.add_user(rnti, uecfg, slot_rx, 0); } tester.run_slot(slot_tx);