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

Commit 947a4338 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "BTM: Switch role after auth complete" am: c0f5c1f5 am: 83475207 am:...

Merge "BTM: Switch role after auth complete" am: c0f5c1f5 am: 83475207 am: 52af5681 am: 7787e38b

Original change: https://android-review.googlesource.com/c/platform/system/bt/+/1824623

Change-Id: I39fa0e85ef4db059d71bbdff3c4e8788ade09969
parents 19b64f90 7787e38b
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -3140,6 +3140,13 @@ void btm_sec_auth_complete(uint16_t handle, tHCI_STATUS status) {
          // indicate that this is encryption after authentication
          BTM_SetEncryption(p_dev_rec->bd_addr, BT_TRANSPORT_BR_EDR, NULL, NULL,
                            BTM_BLE_SEC_NONE);
        } else if (p_dev_rec->IsLocallyInitiated()) {
          // Encryption will be set in role_changed callback
          BTM_TRACE_DEBUG(
              "%s auth completed in role=peripheral, try to switch role and "
              "encrypt",
              __func__);
          BTM_SwitchRoleToCentral(p_dev_rec->RemoteAddress());
        }
      }
      l2cu_start_post_bond_timer(p_dev_rec->hci_handle);