OSDN Git Service

Move _process_num_completed_pkts into acl
authorChris Manton <cmanton@google.com>
Mon, 5 Oct 2020 20:49:56 +0000 (13:49 -0700)
committerChris Manton <cmanton@google.com>
Thu, 8 Oct 2020 06:07:18 +0000 (06:07 +0000)
Bug: 166280067
Tag: #refactor
Test: act.py -tc BleCocTest
Test: ble paired 2 phones
Test: classic paired Bose SoundLink

Change-Id: Ie2237ad8b5ed76c024276a5c2db63c0809c680d9

stack/acl/btm_acl.cc
stack/btu/btu_hcif.cc
stack/include/acl_hci_link_interface.h
stack/include/l2cap_acl_interface.h
stack/include/l2cap_hci_link_interface.h

index a3e420a..e989712 100644 (file)
@@ -55,6 +55,7 @@
 #include "stack/include/acl_api.h"
 #include "stack/include/acl_hci_link_interface.h"
 #include "stack/include/btm_api.h"
+#include "stack/include/btm_iso_api.h"
 #include "stack/include/btu.h"
 #include "stack/include/hcimsgs.h"
 #include "stack/include/l2cap_acl_interface.h"
@@ -2893,3 +2894,8 @@ void acl_rcv_acl_data(BT_HDR* p_msg) {
 void acl_link_segments_xmitted(BT_HDR* p_msg) {
   l2c_link_segments_xmitted(p_msg);
 }
+
+void acl_process_num_completed_pkts(uint8_t* p, uint8_t evt_len) {
+  l2c_link_process_num_completed_pkts(p, evt_len);
+  bluetooth::hci::IsoManager::GetInstance()->HandleNumComplDataPkts(p, evt_len);
+}
index 35f48c6..7fe7984 100644 (file)
@@ -324,8 +324,7 @@ void btu_hcif_process_event(UNUSED_ATTR uint8_t controller_id, BT_HDR* p_msg) {
       btu_hcif_role_change_evt(p);
       break;
     case HCI_NUM_COMPL_DATA_PKTS_EVT:
-      l2c_link_process_num_completed_pkts(p, hci_evt_len);
-      IsoManager::GetInstance()->HandleNumComplDataPkts(p, hci_evt_len);
+      acl_process_num_completed_pkts(p, hci_evt_len);
       break;
     case HCI_MODE_CHANGE_EVT:
       btu_hcif_mode_change_evt(p);
index 1f30e40..c6d9da4 100644 (file)
@@ -51,3 +51,4 @@ void btm_read_tx_power_complete(uint8_t* p, bool is_ble);
 
 void acl_rcv_acl_data(BT_HDR* p_msg);
 void acl_link_segments_xmitted(BT_HDR* p_msg);
+void acl_process_num_completed_pkts(uint8_t* p, uint8_t evt_len);
index 3185409..421c7e7 100644 (file)
@@ -43,3 +43,5 @@ extern void l2c_link_segments_xmitted(BT_HDR* p_msg);
 extern void l2c_link_hci_conn_req(const RawAddress& bd_addr);
 
 extern void l2cu_resubmit_pending_sec_req(const RawAddress* p_bda);
+
+extern void l2c_link_process_num_completed_pkts(uint8_t* p, uint8_t evt_len);
index 7d97f63..63290fe 100644 (file)
@@ -21,8 +21,6 @@
 
 // This header contains functions for HCI-LinkManagement to invoke
 
-extern void l2c_link_process_num_completed_pkts(uint8_t* p, uint8_t evt_len);
-
 extern void l2c_link_hci_conn_comp(uint8_t status, uint16_t handle,
                                    const RawAddress& p_bda);