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

Commit 788d4a52 authored by Chris Manton's avatar Chris Manton
Browse files

Add API stack/acl/btm_acl::BTM_IsAclConnectionUpFromHandle

Working towards encapsulation of tACL_CONN

Bug: 159815595
Tag: #refactor
Test: compile & verify basic functions working
Change-Id: I1f6ffeab5a774a44d536bc1879cb103ee130e129
parent 90353bc2
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -1243,6 +1243,10 @@ bool BTM_IsAclConnectionUpAndHandleValid(const RawAddress& remote_bda,
  return p_acl->hci_handle != HCI_INVALID_HANDLE;
}

bool BTM_IsAclConnectionUpFromHandle(uint16_t hci_handle) {
  return acl_get_connection_from_handle(hci_handle) != nullptr;
}

/*******************************************************************************
 *
 * Function         BTM_GetNumAclLinks
+2 −0
Original line number Diff line number Diff line
@@ -93,6 +93,8 @@ bool BTM_IsAclConnectionUp(const RawAddress& remote_bda,
bool BTM_IsAclConnectionUpAndHandleValid(const RawAddress& remote_bda,
                                         tBT_TRANSPORT transport);

bool BTM_IsAclConnectionUpFromHandle(uint16_t hci_handle);

/*******************************************************************************
 *
 * Function         BTM_GetRole