OSDN Git Service

Move BTM_IS_BRCM_CONTROLLER to end usecase
authorChris Manton <cmanton@google.com>
Thu, 10 Sep 2020 23:23:45 +0000 (16:23 -0700)
committerChris Manton <cmanton@google.com>
Fri, 18 Sep 2020 17:49:59 +0000 (10:49 -0700)
From: stack/btm/security_device_record.h
Into: stack/l2cap/l2c_utils.cc

Towards readable code

Bug: 163134718
Tag: #refactor
Test: compile & verify basic functions working
Test: act.py -tc BleCocTest

Change-Id: I4c69507efdabc35d7e7f393ac3e92481a0666d98

stack/btm/security_device_record.h
stack/l2cap/l2c_utils.cc

index ae5d61f..601613b 100644 (file)
 
 typedef char tBTM_LOC_BD_NAME[BTM_MAX_LOC_BD_NAME_LEN + 1];
 
-#define BTM_IS_BRCM_CONTROLLER()                                 \
-  (controller_get_interface()->get_bt_version()->manufacturer == \
-   LMP_COMPID_BROADCOM)
-
 typedef struct {
   uint16_t min_conn_int;
   uint16_t max_conn_int;
index feabb0c..19b8475 100644 (file)
@@ -2202,6 +2202,10 @@ bool l2cu_lcb_disconnecting(void) {
  *
  ******************************************************************************/
 
+#define BTM_IS_BRCM_CONTROLLER()                                 \
+  (controller_get_interface()->get_bt_version()->manufacturer == \
+   LMP_COMPID_BROADCOM)
+
 bool l2cu_set_acl_priority(const RawAddress& bd_addr, uint8_t priority,
                            bool reset_after_rs) {
   tL2C_LCB* p_lcb;