Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c85e663d authored by Qasim Javed's avatar Qasim Javed
Browse files

Add more logs when modules and their dependencies are started

Bug: 189194098
Test: logs
Tag: #gd-refactor

Change-Id: I1ff6636913b47e73c680dd9f7377361bda100b64
parent 717a0472
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -78,6 +78,7 @@ class InternalHciCallbacks : public IBluetoothHciCallbacks {
  }

  void ResetCallback() {
    LOG_INFO("callbacks have been reset!");
    callback_ = nullptr;
  }

@@ -87,6 +88,7 @@ class InternalHciCallbacks : public IBluetoothHciCallbacks {

  Return<void> initializationComplete(HidlStatus status) {
    common::StopWatch stop_watch(__func__);
    LOG_INFO("initialization complete with status: %d", status);
    ASSERT(status == HidlStatus::SUCCESS);
    init_promise_->set_value();
    return Void();
+4 −4
Original line number Diff line number Diff line
@@ -82,21 +82,21 @@ Module* ModuleRegistry::Start(const ModuleFactory* module, Thread* thread) {
    return started_instance->second;
  }

  LOG_DEBUG("Constructing next module");
  LOG_INFO("Constructing next module");
  Module* instance = module->ctor_();
  last_instance_ = "starting " + instance->ToString();
  set_registry_and_handler(instance, thread);

  LOG_DEBUG("Starting dependencies of %s", instance->ToString().c_str());
  LOG_INFO("Starting dependencies of %s", instance->ToString().c_str());
  instance->ListDependencies(&instance->dependencies_);
  Start(&instance->dependencies_, thread);

  LOG_DEBUG("Finished starting dependencies and calling Start() of %s", instance->ToString().c_str());
  LOG_INFO("Finished starting dependencies and calling Start() of %s", instance->ToString().c_str());

  instance->Start();
  start_order_.push_back(module);
  started_modules_[module] = instance;
  LOG_DEBUG("Started %s", instance->ToString().c_str());
  LOG_INFO("Started %s", instance->ToString().c_str());
  return instance;
}

+2 −0
Original line number Diff line number Diff line
@@ -49,6 +49,8 @@ void StackManager::StartUp(ModuleList* modules, Thread* stack_thread) {

  WakelockManager::Get().Release();

  LOG_INFO("init_status == %d", init_status);

  ASSERT_LOG(
      init_status == std::future_status::ready,
      "Can't start stack, last instance: %s",