/system/nfc/src/nfc/ndef/ |
D | ndef_utils.cc | 76 uint8_t* p_rec = p_msg; in NDEF_MsgValidate() local 93 for (count = 0; p_rec < p_end; count++) { in NDEF_MsgValidate() 95 if (p_rec + 3 > p_end) return (NDEF_MSG_TOO_SHORT); in NDEF_MsgValidate() 97 rec_hdr = *p_rec++; in NDEF_MsgValidate() 108 type_len = *p_rec++; in NDEF_MsgValidate() 118 payload_len = *p_rec++; in NDEF_MsgValidate() 121 if (p_rec + 4 > p_end) return (NDEF_MSG_TOO_SHORT); in NDEF_MsgValidate() 123 BE_STREAM_TO_UINT32(payload_len, p_rec); in NDEF_MsgValidate() 129 if (p_rec + 1 > p_end) return (NDEF_MSG_TOO_SHORT); in NDEF_MsgValidate() 131 id_len = *p_rec++; in NDEF_MsgValidate() [all …]
|
/system/bt/stack/sdp/ |
D | sdp_db.cc | 53 tSDP_RECORD* sdp_db_service_search(tSDP_RECORD* p_rec, tSDP_UUID_SEQ* p_seq) { in sdp_db_service_search() argument 60 if (!p_rec) in sdp_db_service_search() 61 p_rec = &sdp_cb.server_db.record[0]; in sdp_db_service_search() 63 p_rec++; in sdp_db_service_search() 67 for (; p_rec < p_end; p_rec++) { in sdp_db_service_search() 69 p_attr = &p_rec->attribute[0]; in sdp_db_service_search() 70 for (xx = 0; xx < p_rec->num_attributes; xx++, p_attr++) { in sdp_db_service_search() 84 if (xx == p_rec->num_attributes) break; in sdp_db_service_search() 88 if (yy == p_seq->num_uids) return (p_rec); in sdp_db_service_search() 145 tSDP_RECORD* p_rec; in sdp_db_find_record() local [all …]
|
D | sdp_api.cc | 220 tSDP_DISC_ATTR* SDP_FindAttributeInRec(tSDP_DISC_REC* p_rec, uint16_t attr_id) { in SDP_FindAttributeInRec() argument 223 p_attr = p_rec->p_first_attr; in SDP_FindAttributeInRec() 247 bool SDP_FindServiceUUIDInRec(tSDP_DISC_REC* p_rec, Uuid* p_uuid) { in SDP_FindServiceUUIDInRec() argument 250 p_attr = p_rec->p_first_attr; in SDP_FindServiceUUIDInRec() 320 bool SDP_FindServiceUUIDInRec_128bit(tSDP_DISC_REC* p_rec, Uuid* p_uuid) { in SDP_FindServiceUUIDInRec_128bit() argument 321 tSDP_DISC_ATTR* p_attr = p_rec->p_first_attr; in SDP_FindServiceUUIDInRec_128bit() 366 tSDP_DISC_REC* p_rec; in SDP_FindServiceInDb() local 373 p_rec = p_db->p_first_rec; in SDP_FindServiceInDb() 375 p_rec = p_start_rec->p_next_rec; in SDP_FindServiceInDb() 377 while (p_rec) { in SDP_FindServiceInDb() [all …]
|
D | sdp_utils.cc | 63 tSDP_DISC_REC* p_rec) { in sdpu_find_profile_version() argument 65 for (tSDP_DISC_ATTR* p_attr = p_rec->p_first_attr; p_attr != nullptr; in sdpu_find_profile_version() 117 static uint16_t sdpu_find_most_specific_service_uuid(tSDP_DISC_REC* p_rec) { in sdpu_find_most_specific_service_uuid() argument 118 for (tSDP_DISC_ATTR* p_attr = p_rec->p_first_attr; p_attr != nullptr; in sdpu_find_most_specific_service_uuid() 159 for (tSDP_DISC_REC* p_rec = p_db->p_first_rec; p_rec != nullptr; in sdpu_log_attribute_metrics() local 160 p_rec = p_rec->p_next_rec) { in sdpu_log_attribute_metrics() 161 uint16_t service_uuid = sdpu_find_most_specific_service_uuid(p_rec); in sdpu_log_attribute_metrics() 170 auto uuid_version_array = sdpu_find_profile_version(p_rec); in sdpu_log_attribute_metrics() 198 if (SDP_FindProtocolListElemInRec(p_rec, protocol_uuid, in sdpu_log_attribute_metrics() 219 SDP_FindAttributeInRec(p_rec, ATTR_ID_SUPPORTED_FEATURES); in sdpu_log_attribute_metrics() [all …]
|
D | sdp_server.cc | 185 tSDP_RECORD* p_rec = NULL; in process_service_search() local 209 p_rec = sdp_db_service_search(p_rec, &uid_seq); in process_service_search() 211 if (p_rec) in process_service_search() 212 rsp_handles[num_rsp_handles++] = p_rec->record_handle; in process_service_search() 314 tSDP_RECORD* p_rec; in process_service_attr_req() local 349 p_rec = sdp_db_find_record(rec_handle); in process_service_attr_req() 350 if (!p_rec) { in process_service_attr_req() 399 p_attr = sdp_db_find_attr_in_rec(p_rec, attr_seq.attr_entry[xx].start, in process_service_attr_req() 468 p_ccb->list_len = sdpu_get_attrib_seq_len(p_rec, &attr_seq_sav) + 3; in process_service_attr_req() 548 tSDP_RECORD* p_rec; in process_service_search_attr_req() local [all …]
|
D | sdp_discovery.cc | 55 tSDP_DISC_REC* p_rec, uint16_t attr_id, 699 tSDP_DISC_REC* p_rec; in save_attr_seq() local 714 p_rec = add_record(p_ccb->p_db, p_ccb->device_address); in save_attr_seq() 715 if (!p_rec) { in save_attr_seq() 738 p = add_attr(p, p_seq_end, p_ccb->p_db, p_rec, attr_id, NULL, 0); in save_attr_seq() 759 tSDP_DISC_REC* p_rec; in add_record() local 764 p_rec = (tSDP_DISC_REC*)p_db->p_free_mem; in add_record() 768 p_rec->p_first_attr = NULL; in add_record() 769 p_rec->p_next_rec = NULL; in add_record() 771 p_rec->remote_bd_addr = p_bda; in add_record() [all …]
|
D | sdpint.h | 232 extern uint16_t sdpu_get_attrib_seq_len(tSDP_RECORD* p_rec, 241 extern tSDP_RECORD* sdp_db_service_search(tSDP_RECORD* p_rec, 244 extern tSDP_ATTRIBUTE* sdp_db_find_attr_in_rec(tSDP_RECORD* p_rec,
|
/system/bt/bta/sdp/ |
D | bta_sdp_act.cc | 52 tSDP_DISC_REC* p_rec) { in bta_create_mns_sdp_record() argument 64 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_MAP_SUPPORTED_FEATURES); in bta_create_mns_sdp_record() 69 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_SERVICE_NAME); in bta_create_mns_sdp_record() 76 if (SDP_FindProfileVersionInRec(p_rec, UUID_SERVCLASS_MAP_PROFILE, in bta_create_mns_sdp_record() 81 if (SDP_FindProtocolListElemInRec(p_rec, UUID_PROTOCOL_RFCOMM, &pe)) { in bta_create_mns_sdp_record() 85 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_GOEP_L2CAP_PSM); in bta_create_mns_sdp_record() 92 tSDP_DISC_REC* p_rec) { in bta_create_mas_sdp_record() argument 107 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_MAS_INSTANCE_ID); in bta_create_mas_sdp_record() 112 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_SUPPORTED_MSG_TYPE); in bta_create_mas_sdp_record() 117 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_MAP_SUPPORTED_FEATURES); in bta_create_mas_sdp_record() [all …]
|
/system/bt/stack/btm/ |
D | btm_ble.cc | 1275 tBTM_SEC_DEV_REC* p_rec; in btm_sec_save_le_key() local 1284 if ((p_rec = btm_find_dev(bd_addr)) != NULL && in btm_sec_save_le_key() 1286 btm_ble_init_pseudo_addr(p_rec, bd_addr); in btm_sec_save_le_key() 1290 p_rec->ble.keys.pltk = p_keys->penc_key.ltk; in btm_sec_save_le_key() 1291 memcpy(p_rec->ble.keys.rand, p_keys->penc_key.rand, BT_OCTET8_LEN); in btm_sec_save_le_key() 1292 p_rec->ble.keys.sec_level = p_keys->penc_key.sec_level; in btm_sec_save_le_key() 1293 p_rec->ble.keys.ediv = p_keys->penc_key.ediv; in btm_sec_save_le_key() 1294 p_rec->ble.keys.key_size = p_keys->penc_key.key_size; in btm_sec_save_le_key() 1295 p_rec->ble.key_type |= BTM_LE_KEY_PENC; in btm_sec_save_le_key() 1296 p_rec->sec_flags |= BTM_SEC_LE_LINK_KEY_KNOWN; in btm_sec_save_le_key() [all …]
|
/system/bt/bta/mce/ |
D | bta_mce_act.cc | 61 tSDP_DISC_REC* p_rec = NULL; in bta_mce_search_cback() local 80 p_rec = SDP_FindServiceUUIDInDb(p_bta_mce_cfg->p_sdp_db, bta_mce_mas_uuid, in bta_mce_search_cback() 81 p_rec); in bta_mce_search_cback() 83 APPL_TRACE_DEBUG("p_rec:%p", p_rec); in bta_mce_search_cback() 85 if (p_rec == NULL) break; in bta_mce_search_cback() 87 if (!SDP_FindProtocolListElemInRec(p_rec, UUID_PROTOCOL_RFCOMM, &pe)) in bta_mce_search_cback() 92 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_SERVICE_NAME); in bta_mce_search_cback() 99 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_MAS_INSTANCE_ID); in bta_mce_search_cback() 104 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_SUPPORTED_MSG_TYPE); in bta_mce_search_cback() 110 } while (p_rec != NULL && found < BTA_MCE_MAX_MAS_INSTANCES); in bta_mce_search_cback()
|
/system/bt/stack/hid/ |
D | hidh_api.cc | 71 void hidh_get_str_attr(tSDP_DISC_REC* p_rec, uint16_t attr_id, uint16_t max_len, in hidh_get_str_attr() argument 76 p_attr = SDP_FindAttributeInRec(p_rec, attr_id); in hidh_get_str_attr() 92 tSDP_DISC_REC* p_rec; in hidh_search_callback() local 106 p_rec = SDP_FindServiceUUIDInDb(p_db, hid_uuid, NULL); in hidh_search_callback() 107 if (p_rec == NULL) { in hidh_search_callback() 115 if (((p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_HID_DESCRIPTOR_LIST)) == in hidh_search_callback() 132 if (((p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_HID_VIRTUAL_CABLE)) != in hidh_search_callback() 139 p_rec, ATTR_ID_HID_RECONNECT_INITIATE)) != NULL) && in hidh_search_callback() 145 p_rec, ATTR_ID_HID_NORMALLY_CONNECTABLE)) != NULL) && in hidh_search_callback() 150 if (((p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_HID_SDP_DISABLE)) != in hidh_search_callback() [all …]
|
/system/nfc/src/nfc/include/ |
D | ndef_utils.h | 208 extern uint8_t* NDEF_RecGetType(uint8_t* p_rec, uint8_t* p_tnf, 221 extern uint8_t* NDEF_RecGetId(uint8_t* p_rec, uint8_t* p_id_len); 234 extern uint8_t* NDEF_RecGetPayload(uint8_t* p_rec, uint32_t* p_payload_len); 280 uint32_t* p_cur_size, uint8_t* p_rec, 296 uint32_t* p_cur_size, uint8_t* p_rec, 312 uint32_t* p_cur_size, uint8_t* p_rec, 328 uint32_t* p_cur_size, uint8_t* p_rec,
|
/system/bt/bta/hf_client/ |
D | bta_hf_client_sdp.cc | 223 tSDP_DISC_REC* p_rec = NULL; in bta_hf_client_sdp_find_attr() local 233 p_rec = SDP_FindServiceInDb(client_cb->p_disc_db, in bta_hf_client_sdp_find_attr() 234 UUID_SERVCLASS_AG_HANDSFREE, p_rec); in bta_hf_client_sdp_find_attr() 235 if (p_rec == NULL) { in bta_hf_client_sdp_find_attr() 241 if (SDP_FindProtocolListElemInRec(p_rec, UUID_PROTOCOL_RFCOMM, &pe)) { in bta_hf_client_sdp_find_attr() 249 SDP_FindProfileVersionInRec(p_rec, UUID_SERVCLASS_HF_HANDSFREE, in bta_hf_client_sdp_find_attr() 253 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_SUPPORTED_FEATURES); in bta_hf_client_sdp_find_attr() 268 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_NETWORK); in bta_hf_client_sdp_find_attr()
|
/system/bt/stack/a2dp/ |
D | a2dp_api.cc | 66 tSDP_DISC_REC* p_rec = NULL; in a2dp_sdp_cback() local 79 if ((p_rec = SDP_FindServiceInDb( in a2dp_sdp_cback() 80 a2dp_cb.find.p_db, a2dp_cb.find.service_uuid, p_rec)) == NULL) { in a2dp_sdp_cback() 84 peer_address = p_rec->remote_bd_addr; in a2dp_sdp_cback() 87 if ((p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_SERVICE_NAME)) != in a2dp_sdp_cback() 94 if ((p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_PROVIDER_NAME)) != in a2dp_sdp_cback() 102 p_rec, ATTR_ID_SUPPORTED_FEATURES)) != NULL) { in a2dp_sdp_cback() 107 if (SDP_FindProtocolListElemInRec(p_rec, UUID_PROTOCOL_AVDTP, &elem)) { in a2dp_sdp_cback()
|
/system/nfc/src/nfa/dm/ |
D | nfa_dm_ndef.cc | 373 uint8_t *p_rec, *p_ndef_start, *p_type, *p_payload, *p_rec_end; in nfa_dm_ndef_handle_message() local 439 p_rec = p_ndef_start = p_msg_buf; in nfa_dm_ndef_handle_message() 442 while (p_rec != nullptr) { in nfa_dm_ndef_handle_message() 444 p_type = NDEF_RecGetType(p_rec, &tnf, &type_len); in nfa_dm_ndef_handle_message() 450 p_payload = NDEF_RecGetPayload(p_rec, &payload_len); in nfa_dm_ndef_handle_message() 479 ndef_data.p_data = p_rec; /* Start of record */ in nfa_dm_ndef_handle_message() 483 ndef_data.len = payload_len + (uint32_t)(p_payload - p_rec); in nfa_dm_ndef_handle_message() 486 p_rec_end = p_rec; in nfa_dm_ndef_handle_message() 508 ndef_data.len = (uint32_t)(p_rec_end - p_rec); in nfa_dm_ndef_handle_message() 547 p_rec = NDEF_MsgGetNextRec(p_rec); in nfa_dm_ndef_handle_message()
|
/system/bt/bta/ag/ |
D | bta_ag_sdp.cc | 293 tSDP_DISC_REC* p_rec = nullptr; in bta_ag_sdp_find_attr() local 316 p_rec = SDP_FindServiceInDb(p_scb->p_disc_db, uuid, p_rec); in bta_ag_sdp_find_attr() 317 if (p_rec == nullptr) { in bta_ag_sdp_find_attr() 322 p_rec = SDP_FindServiceInDb(p_scb->p_disc_db, uuid, p_rec); in bta_ag_sdp_find_attr() 323 if (p_rec == nullptr) { in bta_ag_sdp_find_attr() 332 if (SDP_FindProtocolListElemInRec(p_rec, UUID_PROTOCOL_RFCOMM, &pe)) { in bta_ag_sdp_find_attr() 341 if (!SDP_FindProfileVersionInRec(p_rec, uuid, &peer_version)) { in bta_ag_sdp_find_attr() 361 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_SUPPORTED_FEATURES); in bta_ag_sdp_find_attr() 398 SDP_FindAttributeInRec(p_rec, ATTR_ID_REMOTE_AUDIO_VOLUME_CONTROL); in bta_ag_sdp_find_attr()
|
/system/bt/stack/include/ |
D | sdp_api.h | 248 tSDP_DISC_ATTR* SDP_FindAttributeInRec(tSDP_DISC_REC* p_rec, uint16_t attr_id); 299 bool SDP_FindServiceUUIDInRec_128bit(tSDP_DISC_REC* p_rec, 328 bool SDP_FindProtocolListElemInRec(tSDP_DISC_REC* p_rec, uint16_t layer_uuid, 345 bool SDP_FindProfileVersionInRec(tSDP_DISC_REC* p_rec, uint16_t profile_uuid, 590 bool SDP_FindServiceUUIDInRec(tSDP_DISC_REC* p_rec, bluetooth::Uuid* p_uuid);
|
/system/bt/bta/av/ |
D | bta_av_act.cc | 1631 tSDP_DISC_REC* p_rec = NULL; in bta_av_check_peer_features() local 1640 p_rec = SDP_FindServiceInDb(p_cb->p_disc_db, service_uuid, p_rec); in bta_av_check_peer_features() 1641 if (p_rec == NULL) { in bta_av_check_peer_features() 1645 if ((SDP_FindAttributeInRec(p_rec, ATTR_ID_SERVICE_CLASS_ID_LIST)) != in bta_av_check_peer_features() 1658 if ((SDP_FindAttributeInRec(p_rec, ATTR_ID_BT_PROFILE_DESC_LIST)) != NULL) { in bta_av_check_peer_features() 1660 SDP_FindProfileVersionInRec(p_rec, UUID_SERVCLASS_AV_REMOTE_CONTROL, in bta_av_check_peer_features() 1669 p_attr = SDP_FindAttributeInRec(p_rec, ATTR_ID_SUPPORTED_FEATURES); in bta_av_check_peer_features() 1701 tSDP_DISC_REC* p_rec = in bta_avk_check_peer_features() local 1703 while (p_rec) { in bta_avk_check_peer_features() 1707 if ((SDP_FindAttributeInRec(p_rec, ATTR_ID_SERVICE_CLASS_ID_LIST)) != in bta_avk_check_peer_features() [all …]
|