Loading system/btif/include/btif_storage.h +1 −0 Original line number Diff line number Diff line Loading @@ -30,6 +30,7 @@ #define BTIF_STORAGE_FILL_PROPERTY(p_prop, t, l, p_v) \ (p_prop)->type = t;(p_prop)->len = l; (p_prop)->val = (p_v); #define BTIF_STORAGE_MAX_ALLOWED_REMOTE_DEVICE 512 /******************************************************************************* ** Functions Loading system/btif/src/btif_gatt_client.c +24 −3 Original line number Diff line number Diff line Loading @@ -463,10 +463,31 @@ static void btif_gattc_upstreams_evt(uint16_t event, char* p_param) case BTIF_GATT_OBSERVE_EVT: { btif_gattc_cb_t *p_btif_cb = (btif_gattc_cb_t*)p_param; uint8_t remote_name_len; uint8_t *p_eir_remote_name=NULL; p_eir_remote_name = BTA_CheckEirData(p_btif_cb->value, BTM_EIR_COMPLETE_LOCAL_NAME_TYPE, &remote_name_len); if(p_eir_remote_name == NULL) { p_eir_remote_name = BTA_CheckEirData(p_btif_cb->value, BT_EIR_SHORTENED_LOCAL_NAME_TYPE, &remote_name_len); } if ((p_btif_cb->addr_type != BLE_ADDR_RANDOM) || (p_eir_remote_name)) { if (!btif_gattc_find_bdaddr(p_btif_cb->bd_addr.address)) { static const char* exclude_filter[] = {"LinkKey", "LE_KEY_PENC", "LE_KEY_PID", "LE_KEY_PCSRK", "LE_KEY_LENC", "LE_KEY_LCSRK"}; btif_gattc_add_remote_bdaddr(p_btif_cb->bd_addr.address, p_btif_cb->addr_type); btif_gattc_update_properties(p_btif_cb); btif_config_filter_remove("Remote", exclude_filter, sizeof(exclude_filter)/sizeof(char*), BTIF_STORAGE_MAX_ALLOWED_REMOTE_DEVICE); } } HAL_CBACK(bt_gatt_callbacks, client->scan_result_cb, &p_btif_cb->bd_addr, p_btif_cb->rssi, p_btif_cb->value); Loading system/btif/src/btif_storage.c +1 −2 Original line number Diff line number Diff line Loading @@ -38,7 +38,7 @@ #define LOG_TAG "BTIF_STORAGE" #include "btif_api.h" #include "btif_storage.h" #include "btif_util.h" #include "bd.h" #include "gki.h" Loading Loading @@ -150,7 +150,6 @@ #define BTIF_STORAGE_HL_APP_DATA "hl_app_data_" #define BTIF_STORAGE_HL_APP_MDL_DATA "hl_app_mdl_data_" #define BTIF_STORAGE_MAX_ALLOWED_REMOTE_DEVICE 512 /************************************************************************************ ** Local type definitions ************************************************************************************/ Loading Loading
system/btif/include/btif_storage.h +1 −0 Original line number Diff line number Diff line Loading @@ -30,6 +30,7 @@ #define BTIF_STORAGE_FILL_PROPERTY(p_prop, t, l, p_v) \ (p_prop)->type = t;(p_prop)->len = l; (p_prop)->val = (p_v); #define BTIF_STORAGE_MAX_ALLOWED_REMOTE_DEVICE 512 /******************************************************************************* ** Functions Loading
system/btif/src/btif_gatt_client.c +24 −3 Original line number Diff line number Diff line Loading @@ -463,10 +463,31 @@ static void btif_gattc_upstreams_evt(uint16_t event, char* p_param) case BTIF_GATT_OBSERVE_EVT: { btif_gattc_cb_t *p_btif_cb = (btif_gattc_cb_t*)p_param; uint8_t remote_name_len; uint8_t *p_eir_remote_name=NULL; p_eir_remote_name = BTA_CheckEirData(p_btif_cb->value, BTM_EIR_COMPLETE_LOCAL_NAME_TYPE, &remote_name_len); if(p_eir_remote_name == NULL) { p_eir_remote_name = BTA_CheckEirData(p_btif_cb->value, BT_EIR_SHORTENED_LOCAL_NAME_TYPE, &remote_name_len); } if ((p_btif_cb->addr_type != BLE_ADDR_RANDOM) || (p_eir_remote_name)) { if (!btif_gattc_find_bdaddr(p_btif_cb->bd_addr.address)) { static const char* exclude_filter[] = {"LinkKey", "LE_KEY_PENC", "LE_KEY_PID", "LE_KEY_PCSRK", "LE_KEY_LENC", "LE_KEY_LCSRK"}; btif_gattc_add_remote_bdaddr(p_btif_cb->bd_addr.address, p_btif_cb->addr_type); btif_gattc_update_properties(p_btif_cb); btif_config_filter_remove("Remote", exclude_filter, sizeof(exclude_filter)/sizeof(char*), BTIF_STORAGE_MAX_ALLOWED_REMOTE_DEVICE); } } HAL_CBACK(bt_gatt_callbacks, client->scan_result_cb, &p_btif_cb->bd_addr, p_btif_cb->rssi, p_btif_cb->value); Loading
system/btif/src/btif_storage.c +1 −2 Original line number Diff line number Diff line Loading @@ -38,7 +38,7 @@ #define LOG_TAG "BTIF_STORAGE" #include "btif_api.h" #include "btif_storage.h" #include "btif_util.h" #include "bd.h" #include "gki.h" Loading Loading @@ -150,7 +150,6 @@ #define BTIF_STORAGE_HL_APP_DATA "hl_app_data_" #define BTIF_STORAGE_HL_APP_MDL_DATA "hl_app_mdl_data_" #define BTIF_STORAGE_MAX_ALLOWED_REMOTE_DEVICE 512 /************************************************************************************ ** Local type definitions ************************************************************************************/ Loading