applied changes in the stack internal method naming

master
Francisco Paisana 5 years ago committed by Andre Puschmann
parent ce29ed545d
commit 8f8d9f3f30

@ -115,8 +115,8 @@ public:
private:
void run_thread() final;
void run_tti_(uint32_t tti);
void stop_();
void run_tti_impl(uint32_t tti);
void stop_impl();
bool running;
srsue::stack_args_t args;

@ -116,22 +116,19 @@ int ue_stack_lte::init(const stack_args_t& args_, srslte::logger* logger_)
void ue_stack_lte::stop()
{
if (running) {
pending_tasks.push([this]() { stop_(); });
pending_tasks.push([this]() { stop_impl(); });
running = false;
wait_thread_finish();
}
}
void ue_stack_lte::stop_()
void ue_stack_lte::stop_impl()
{
if (running) {
usim->stop();
nas.stop();
rrc.stop();
// Caution here order of stop is very important to avoid locks
// Stop RLC and PDCP before GW to avoid locking on queue
rlc.stop();
pdcp.stop();
mac.stop();
@ -142,9 +139,6 @@ void ue_stack_lte::stop_()
if (args.pcap.nas_enable) {
nas_pcap.close();
}
running = false;
}
}
bool ue_stack_lte::switch_on()
@ -217,10 +211,10 @@ void ue_stack_lte::out_of_sync()
void ue_stack_lte::run_tti(uint32_t tti)
{
pending_tasks.push([this, tti]() { run_tti_(tti); });
pending_tasks.push([this, tti]() { run_tti_impl(tti); });
}
void ue_stack_lte::run_tti_(uint32_t tti)
void ue_stack_lte::run_tti_impl(uint32_t tti)
{
mac.run_tti(tti);
rrc.run_tti(tti);

@ -148,14 +148,7 @@ public:
pdcp->write_sdu(lcid, std::move(sdu), blocking);
}
bool is_lcid_enabled(uint32_t lcid) { return pdcp->is_lcid_enabled(lcid); }
void run_thread()
{
running = true;
uint32_t counter = 0;
// while (running) {
// nas->run_tti(counter++);
// }
}
void run_thread() { running = true; }
void stop()
{
running = false;

Loading…
Cancel
Save