mirror of https://github.com/pvnis/srsRAN_4G.git
You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
72 lines
2.0 KiB
C
72 lines
2.0 KiB
C
4 years ago
|
/**
|
||
4 years ago
|
* Copyright 2013-2021 Software Radio Systems Limited
|
||
4 years ago
|
*
|
||
4 years ago
|
* This file is part of srsRAN.
|
||
4 years ago
|
*
|
||
4 years ago
|
* srsRAN is free software: you can redistribute it and/or modify
|
||
|
* it under the terms of the GNU Affero General Public License as
|
||
|
* published by the Free Software Foundation, either version 3 of
|
||
|
* the License, or (at your option) any later version.
|
||
|
*
|
||
|
* srsRAN is distributed in the hope that it will be useful,
|
||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||
|
* GNU Affero General Public License for more details.
|
||
4 years ago
|
*
|
||
4 years ago
|
* A copy of the GNU Affero General Public License can be found in
|
||
|
* the LICENSE file in the top-level directory of this distribution
|
||
|
* and at http://www.gnu.org/licenses/.
|
||
4 years ago
|
*
|
||
|
*/
|
||
|
|
||
|
#ifndef SRSRAN_SCHED_NR_WORKER_H
|
||
|
#define SRSRAN_SCHED_NR_WORKER_H
|
||
|
|
||
3 years ago
|
#include "sched_nr_bwp.h"
|
||
4 years ago
|
#include "sched_nr_cfg.h"
|
||
3 years ago
|
#include "sched_nr_grant_allocator.h"
|
||
4 years ago
|
#include "sched_nr_ue.h"
|
||
|
#include "srsran/adt/circular_array.h"
|
||
|
#include "srsran/adt/optional.h"
|
||
|
#include "srsran/adt/pool/cached_alloc.h"
|
||
|
#include "srsran/adt/span.h"
|
||
|
#include <condition_variable>
|
||
|
#include <mutex>
|
||
|
|
||
|
namespace srsenb {
|
||
|
|
||
3 years ago
|
struct mac_metrics_t;
|
||
|
|
||
4 years ago
|
namespace sched_nr_impl {
|
||
4 years ago
|
|
||
3 years ago
|
class cc_worker
|
||
4 years ago
|
{
|
||
|
public:
|
||
3 years ago
|
explicit cc_worker(const cell_params_t& params);
|
||
4 years ago
|
|
||
3 years ago
|
void dl_rach_info(const sched_nr_interface::rar_info_t& rar_info);
|
||
4 years ago
|
|
||
3 years ago
|
dl_sched_res_t* run_slot(slot_point pdcch_slot, ue_map_t& ue_db_);
|
||
|
ul_sched_t* get_ul_sched(slot_point sl);
|
||
4 years ago
|
|
||
3 years ago
|
// const params
|
||
3 years ago
|
const cell_params_t& cfg;
|
||
|
srslog::basic_logger& logger;
|
||
4 years ago
|
|
||
3 years ago
|
// cc-specific resources
|
||
|
srsran::bounded_vector<bwp_manager, SCHED_NR_MAX_BWP_PER_CELL> bwps;
|
||
4 years ago
|
|
||
|
private:
|
||
3 years ago
|
void alloc_dl_ues(bwp_slot_allocator& bwp_alloc);
|
||
|
void alloc_ul_ues(bwp_slot_allocator& bwp_alloc);
|
||
|
void postprocess_decisions(bwp_slot_allocator& bwp_alloc);
|
||
4 years ago
|
|
||
3 years ago
|
// {slot,cc} specific variables
|
||
|
slot_ue_map_t slot_ues;
|
||
4 years ago
|
};
|
||
|
|
||
|
} // namespace sched_nr_impl
|
||
|
} // namespace srsenb
|
||
|
|
||
|
#endif // SRSRAN_SCHED_NR_WORKER_H
|