OSDN Git Service

Locally link and remove unused funcs stack/btm/btm_ble_addr
authorChris Manton <cmanton@google.com>
Sun, 20 Sep 2020 01:45:52 +0000 (18:45 -0700)
committerChris Manton <cmanton@google.com>
Wed, 30 Sep 2020 19:38:16 +0000 (12:38 -0700)
Towards readable code

Bug: 163134718
Tag: #refactor
Test: act.py -tc BleCocTest
Change-Id: I38adcdc582a3330e2fab95310e5e706fa40e8c0d

stack/btm/btm_ble_addr.cc

index fc2c2a7..4aeed74 100644 (file)
@@ -41,8 +41,8 @@ void btm_ble_set_random_address(const RawAddress& random_bda);
 
 /* This function generates Resolvable Private Address (RPA) from Identity
  * Resolving Key |irk| and |random|*/
-RawAddress generate_rpa_from_irk_and_rand(const Octet16& irk,
-                                          BT_OCTET8 random) {
+static RawAddress generate_rpa_from_irk_and_rand(const Octet16& irk,
+                                                 BT_OCTET8 random) {
   random[2] &= (~BLE_RESOLVE_ADDR_MASK);
   random[2] |= BLE_RESOLVE_ADDR_MSB;
 
@@ -223,8 +223,8 @@ tBTM_SEC_DEV_REC* btm_ble_resolve_random_addr(const RawAddress& random_bda) {
  *  address mapping between pseudo address and real connection address
  ******************************************************************************/
 /** Find the security record whose LE identity address is matching */
-tBTM_SEC_DEV_REC* btm_find_dev_by_identity_addr(const RawAddress& bd_addr,
-                                                uint8_t addr_type) {
+static tBTM_SEC_DEV_REC* btm_find_dev_by_identity_addr(
+    const RawAddress& bd_addr, uint8_t addr_type) {
   list_node_t* end = list_end(btm_cb.sec_dev_rec);
   for (list_node_t* node = list_begin(btm_cb.sec_dev_rec); node != end;
        node = list_next(node)) {