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

Commit ea59bc83 authored by Chris Manton's avatar Chris Manton
Browse files

Re-log bta/sys/bta_sys_conn::bta_sys_notify_role_chg

Towards loggable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run --host

Change-Id: I66b27249f3b0ca8e947218af817d9f5367304156
parent c36d4607
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -29,6 +29,8 @@
#include "bta/include/utl.h"
#include "bta/sys/bta_sys.h"
#include "bta/sys/bta_sys_int.h"
#include "main/shim/dumpsys.h"
#include "osi/include/log.h"
#include "osi/include/osi.h"

/*******************************************************************************
@@ -85,8 +87,9 @@ void bta_sys_ssr_cfg_register(tBTA_SYS_SSR_CFG_CBACK* p_cback) {
 ******************************************************************************/
void bta_sys_notify_role_chg(const RawAddress& peer_addr, uint8_t new_role,
                             uint8_t hci_status) {
  APPL_TRACE_DEBUG("%s: peer %s new_role:%d hci_status:0x%x", __func__,
                   peer_addr.ToString().c_str(), new_role, hci_status);
  LOG_DEBUG("Role changed peer:%s new_role:%s hci_status:%s",
            PRIVATE_ADDRESS(peer_addr), RoleText(new_role).c_str(),
            hci_error_code_text(hci_status).c_str());
  if (bta_sys_cb.p_role_cb) {
    bta_sys_cb.p_role_cb(BTA_SYS_ROLE_CHANGE, new_role, hci_status, peer_addr);
  }