change enb max_nof_ues config parameter to nof_prealloc_ues

master
Francisco 4 years ago committed by Francisco Paisana
parent 9739a9de5f
commit 5818488b27

@ -22,7 +22,7 @@ struct mac_args_t {
uint32_t nof_prb; ///< Needed to dimension MAC softbuffers for all cells uint32_t nof_prb; ///< Needed to dimension MAC softbuffers for all cells
sched_interface::sched_args_t sched; sched_interface::sched_args_t sched;
int nr_tb_size = -1; int nr_tb_size = -1;
uint32_t max_nof_ues; uint32_t nof_prealloc_ues;
uint32_t max_nof_kos; uint32_t max_nof_kos;
}; };

@ -327,6 +327,6 @@ enable = false
#rrc_inactivity_timer = 30000 #rrc_inactivity_timer = 30000
#max_nof_kos = 100 #max_nof_kos = 100
#max_prach_offset_us = 30 #max_prach_offset_us = 30
#max_nof_ues = 8 #nof_prealloc_ues = 8
#eea_pref_list = EEA0, EEA2, EEA1 #eea_pref_list = EEA0, EEA2, EEA1
#eia_pref_list = EIA2, EIA1, EIA0 #eia_pref_list = EIA2, EIA1, EIA0

@ -905,9 +905,9 @@ int set_derived_args(all_args_t* args_, rrc_cfg_t* rrc_cfg_, phy_cfg_t* phy_cfg_
{ {
// Sanity checks // Sanity checks
ASSERT_VALID_CFG(not rrc_cfg_->cell_list.empty(), "No cell specified in rr.conf."); ASSERT_VALID_CFG(not rrc_cfg_->cell_list.empty(), "No cell specified in rr.conf.");
ASSERT_VALID_CFG(args_->stack.mac.max_nof_ues <= SRSENB_MAX_UES and args_->stack.mac.max_nof_ues > 0, ASSERT_VALID_CFG(args_->stack.mac.nof_prealloc_ues <= SRSENB_MAX_UES,
"mac.max_nof_ues=%d must be within [0, %d]", "mac.nof_prealloc_ues=%d must be within [0, %d]",
args_->stack.mac.max_nof_ues, args_->stack.mac.nof_prealloc_ues,
SRSENB_MAX_UES); SRSENB_MAX_UES);
// Check for a forced DL EARFCN or frequency (only valid for a single cell config (Xico's favorite feature)) // Check for a forced DL EARFCN or frequency (only valid for a single cell config (Xico's favorite feature))

@ -214,7 +214,7 @@ void parse_args(all_args_t* args, int argc, char* argv[])
("expert.print_buffer_state", bpo::value<bool>(&args->general.print_buffer_state)->default_value(false), "Prints on the console the buffer state every 10 seconds") ("expert.print_buffer_state", bpo::value<bool>(&args->general.print_buffer_state)->default_value(false), "Prints on the console the buffer state every 10 seconds")
("expert.eea_pref_list", bpo::value<string>(&args->general.eea_pref_list)->default_value("EEA0, EEA2, EEA1"), "Ordered preference list for the selection of encryption algorithm (EEA) (default: EEA0, EEA2, EEA1).") ("expert.eea_pref_list", bpo::value<string>(&args->general.eea_pref_list)->default_value("EEA0, EEA2, EEA1"), "Ordered preference list for the selection of encryption algorithm (EEA) (default: EEA0, EEA2, EEA1).")
("expert.eia_pref_list", bpo::value<string>(&args->general.eia_pref_list)->default_value("EIA2, EIA1, EIA0"), "Ordered preference list for the selection of integrity algorithm (EIA) (default: EIA2, EIA1, EIA0).") ("expert.eia_pref_list", bpo::value<string>(&args->general.eia_pref_list)->default_value("EIA2, EIA1, EIA0"), "Ordered preference list for the selection of integrity algorithm (EIA) (default: EIA2, EIA1, EIA0).")
("expert.max_nof_ues", bpo::value<uint32_t>(&args->stack.mac.max_nof_ues)->default_value(8), "Maximum number of connected UEs") ("expert.nof_prealloc_ues", bpo::value<uint32_t>(&args->stack.mac.nof_prealloc_ues)->default_value(8), "Number of UE resources to preallocate")
("expert.max_mac_dl_kos", bpo::value<uint32_t>(&args->general.max_mac_dl_kos)->default_value(100), "Maximum number of consecutive KOs in DL before triggering the UE's release") ("expert.max_mac_dl_kos", bpo::value<uint32_t>(&args->general.max_mac_dl_kos)->default_value(100), "Maximum number of consecutive KOs in DL before triggering the UE's release")
("expert.max_mac_ul_kos", bpo::value<uint32_t>(&args->general.max_mac_ul_kos)->default_value(100), "Maximum number of consecutive KOs in UL before triggering the UE's release") ("expert.max_mac_ul_kos", bpo::value<uint32_t>(&args->general.max_mac_ul_kos)->default_value(100), "Maximum number of consecutive KOs in UL before triggering the UE's release")

@ -73,9 +73,9 @@ int enb_stack_lte::init(const stack_args_t& args_, const rrc_cfg_t& rrc_cfg_)
rrc_cfg = rrc_cfg_; rrc_cfg = rrc_cfg_;
// Init RNTI and bearer memory pools // Init RNTI and bearer memory pools
reserve_rnti_memblocks(args.mac.max_nof_ues); reserve_rnti_memblocks(args.mac.nof_prealloc_ues);
uint32_t min_nof_bearers_per_ue = 4; uint32_t min_nof_bearers_per_ue = 4;
reserve_rlc_memblocks(args.mac.max_nof_ues * min_nof_bearers_per_ue); reserve_rlc_memblocks(args.mac.nof_prealloc_ues * min_nof_bearers_per_ue);
// setup logging for each layer // setup logging for each layer
mac_logger.set_level(srslog::str_to_basic_level(args.log.mac_level)); mac_logger.set_level(srslog::str_to_basic_level(args.log.mac_level));

@ -84,7 +84,7 @@ bool mac::init(const mac_args_t& args_,
}; };
auto recycle_softbuffers = [](ue_cc_softbuffers& softbuffers) { softbuffers.clear(); }; auto recycle_softbuffers = [](ue_cc_softbuffers& softbuffers) { softbuffers.clear(); };
softbuffer_pool.reset(new srsran::background_obj_pool<ue_cc_softbuffers>( softbuffer_pool.reset(new srsran::background_obj_pool<ue_cc_softbuffers>(
8, 8, args.max_nof_ues, init_softbuffers, recycle_softbuffers)); 8, 8, args.nof_prealloc_ues, init_softbuffers, recycle_softbuffers));
// Pre-alloc UE objects for first attaching users // Pre-alloc UE objects for first attaching users
prealloc_ue(10); prealloc_ue(10);
@ -469,8 +469,8 @@ uint16_t mac::allocate_ue()
logger.info("RACH ignored as eNB is being shutdown"); logger.info("RACH ignored as eNB is being shutdown");
return SRSRAN_INVALID_RNTI; return SRSRAN_INVALID_RNTI;
} }
if (ue_db.size() >= args.max_nof_ues) { if (ue_db.size() >= SRSENB_MAX_UES) {
logger.warning("Maximum number of connected UEs %zd connected to the eNB. Ignoring PRACH", args.max_nof_ues); logger.warning("Maximum number of connected UEs %zd connected to the eNB. Ignoring PRACH", SRSENB_MAX_UES);
return SRSRAN_INVALID_RNTI; return SRSRAN_INVALID_RNTI;
} }
auto ret = ue_db.insert(rnti, std::move(ue_ptr)); auto ret = ue_db.insert(rnti, std::move(ue_ptr));

@ -60,7 +60,7 @@ int parse_default_cfg(rrc_cfg_t* rrc_cfg, srsenb::all_args_t& args)
args.enb.nof_ports = 1; args.enb.nof_ports = 1;
args.general.eia_pref_list = "EIA2, EIA1, EIA0"; args.general.eia_pref_list = "EIA2, EIA1, EIA0";
args.general.eea_pref_list = "EEA0, EEA2, EEA1"; args.general.eea_pref_list = "EEA0, EEA2, EEA1";
args.stack.mac.max_nof_ues = 2; args.stack.mac.nof_prealloc_ues = 2;
args.general.rrc_inactivity_timer = 60000; args.general.rrc_inactivity_timer = 60000;

Loading…
Cancel
Save