Skip to content

Commit 991aaa6

Browse files
herlesupreethcodebot
authored andcommitted
sched: generate more than one k2 candidate per DL slot in UL heavy TDD configuration
1 parent 70cea8b commit 991aaa6

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

lib/scheduler/config/serving_cell_config_factory.cpp

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -289,19 +289,27 @@ srsran::config_helpers::generate_k2_candidates(cyclic_prefix cp, const tdd_ul_dl
289289
// Maximum number of candidates as per TS 38.331, "maxNrofUL-Allocations".
290290
static constexpr unsigned MAX_SIZE = 16;
291291

292+
const unsigned tdd_period_slots = nof_slots_per_tdd_period(tdd_cfg);
293+
292294
// TODO: This algorithm may need to be revisited for partial UL slots to avoid that the partial slot is always picked.
293295
std::vector<pusch_time_domain_resource_allocation> result;
294296
for (unsigned idx = 0; idx < nof_slots_per_tdd_period(tdd_cfg) and result.size() < MAX_SIZE; ++idx) {
295297
// For every slot containing DL symbols check for corresponding k2 value.
296298
if (get_active_tdd_dl_symbols(tdd_cfg, idx, cp).length() > 0) {
297-
for (unsigned k2 = min_k2; k2 <= SCHEDULER_MAX_K2 and result.size() < MAX_SIZE; ++k2) {
299+
for (unsigned k2 = min_k2; k2 <= SCHEDULER_MAX_K2 and result.size() < MAX_SIZE and k2 < tdd_period_slots; ++k2) {
298300
// TODO: Consider partial UL slots when scheduler supports it.
299301
if (get_active_tdd_ul_symbols(tdd_cfg, idx + k2, cp).length() == SYMBOLS_PER_SLOT) {
300302
if (std::none_of(result.begin(), result.end(), [k2](const auto& res) { return res.k2 == k2; })) {
301303
result.emplace_back(pusch_time_domain_resource_allocation{
302304
k2, sch_mapping_type::typeA, ofdm_symbol_range{0, SYMBOLS_PER_SLOT}});
303305
}
304-
break;
306+
// [Implementation-defined] For DL heavy (nof. of DL slots greater than nof. UL slots) TDD configuration nof.
307+
// k2 values are generated based on nof. DL slots i.e. one k2 value per DL slot. But whereas in the case of UL
308+
// heavy TDD configuration, where we allow multiple UL PDCCH allocations in the same slot for same UE multiple
309+
// k2 values per DL slot are generated.
310+
if (nof_full_dl_slots_per_tdd_period(tdd_cfg) > nof_full_ul_slots_per_tdd_period(tdd_cfg)) {
311+
break;
312+
}
305313
}
306314
}
307315
}

0 commit comments

Comments
 (0)