Lines Matching refs:gatt_cb
115 if (gatt_cb.cb_info.p_srv_chg_callback) { in gatt_delete_dev_from_srv_chg_clt_list()
119 (*gatt_cb.cb_info.p_srv_chg_callback)(GATTS_SRV_CHG_CMD_REMOVE_CLIENT, in gatt_delete_dev_from_srv_chg_clt_list()
122 osi_free(fixed_queue_try_remove_from_queue(gatt_cb.srv_chg_clt_q, p_buf)); in gatt_delete_dev_from_srv_chg_clt_list()
138 if (fixed_queue_is_empty(gatt_cb.srv_chg_clt_q)) return; in gatt_set_srv_chg()
140 list_t* list = fixed_queue_get_list(gatt_cb.srv_chg_clt_q); in gatt_set_srv_chg()
151 if (gatt_cb.cb_info.p_srv_chg_callback) in gatt_set_srv_chg()
152 (*gatt_cb.cb_info.p_srv_chg_callback)(GATTS_SRV_CHG_CMD_UPDATE_CLIENT, in gatt_set_srv_chg()
194 fixed_queue_enqueue(gatt_cb.srv_chg_clt_q, p_buf); in gatt_add_srv_chg_clt()
205 for (auto& elem : *gatt_cb.hdl_list_info) { in gatt_find_hdl_buffer_by_handle()
221 auto end_it = gatt_cb.hdl_list_info->end(); in gatt_find_hdl_buffer_by_app_id()
222 auto it = gatt_cb.hdl_list_info->begin(); in gatt_find_hdl_buffer_by_app_id()
239 auto it = gatt_cb.hdl_list_info->begin(); in gatt_free_srvc_db_buffer_app_id()
240 auto end = gatt_cb.hdl_list_info->end(); in gatt_free_srvc_db_buffer_app_id()
243 it = gatt_cb.hdl_list_info->erase(it); in gatt_free_srvc_db_buffer_app_id()
267 if (gatt_cb.tcb[i].in_use && gatt_cb.tcb[i].ch_state == GATT_CH_OPEN) { in gatt_find_the_connected_bda()
268 bda = gatt_cb.tcb[i].peer_bda; in gatt_find_the_connected_bda()
270 *p_transport = gatt_cb.tcb[i].transport; in gatt_find_the_connected_bda()
294 if (p_tcb->indicate_handle == gatt_cb.handle_of_h_r) return true; in gatt_is_srv_chg_ind_pending()
302 if (p_buf->handle == gatt_cb.handle_of_h_r) { in gatt_is_srv_chg_ind_pending()
325 if (fixed_queue_is_empty(gatt_cb.srv_chg_clt_q)) return NULL; in gatt_is_bda_in_the_srv_chg_clt_list()
327 list_t* list = fixed_queue_get_list(gatt_cb.srv_chg_clt_q); in gatt_is_bda_in_the_srv_chg_clt_list()
354 if (gatt_cb.tcb[i].in_use && gatt_cb.tcb[i].peer_bda == bda) { in gatt_is_bda_connected()
376 if (gatt_cb.tcb[i].peer_bda == bda && in gatt_find_i_tcb_by_addr()
377 gatt_cb.tcb[i].transport == transport) { in gatt_find_i_tcb_by_addr()
396 if ((tcb_idx < GATT_MAX_PHY_CHANNEL) && gatt_cb.tcb[tcb_idx].in_use) in gatt_get_tcb_by_idx()
397 p_tcb = &gatt_cb.tcb[tcb_idx]; in gatt_get_tcb_by_idx()
417 if (i != GATT_INDEX_INVALID) p_tcb = &gatt_cb.tcb[i]; in gatt_find_tcb_by_addr()
435 if (j != GATT_INDEX_INVALID) return &gatt_cb.tcb[j]; in gatt_allocate_tcb_by_bdaddr()
439 tGATT_TCB* p_tcb = &gatt_cb.tcb[i]; in gatt_allocate_tcb_by_bdaddr()
654 auto it = gatt_cb.srv_list_info->begin(); in gatt_sr_find_i_rcb_by_handle()
656 for (; it != gatt_cb.srv_list_info->end(); it++) { in gatt_sr_find_i_rcb_by_handle()
821 gatt_cb.enable_err_rsp = enable; in gatt_set_err_rsp()
822 gatt_cb.req_op_code = req_op_code; in gatt_set_err_rsp()
823 gatt_cb.err_status = err_status; in gatt_set_err_rsp()
846 p_reg = &gatt_cb.cl_rcb[ii - 1]; in gatt_get_regcb()
871 if (gatt_cb.clcb[i].in_use && (gatt_cb.clcb[i].conn_id == conn_id)) { in gatt_is_clcb_allocated()
899 if (!gatt_cb.clcb[i].in_use) { in gatt_clcb_alloc()
900 p_clcb = &gatt_cb.clcb[i]; in gatt_clcb_alloc()
945 if (gatt_cb.tcb[xx].in_use && gatt_cb.tcb[xx].att_lcid == lcid) { in gatt_find_tcb_by_cid()
946 p_tcb = &gatt_cb.tcb[xx]; in gatt_find_tcb_by_cid()
966 if (gatt_cb.clcb[i].in_use && gatt_cb.clcb[i].p_tcb->peer_bda == bda) num++; in gatt_num_clcb_by_bd_addr()
1249 tGATT_CLCB* p_clcb = &gatt_cb.clcb[i]; in gatt_cleanup_upon_disc()
1271 tGATT_REG* p_reg = &gatt_cb.cl_rcb[i]; in gatt_cleanup_upon_disc()
1319 for (tGATT_BG_CONN_DEV& dev : gatt_cb.bgconn_dev) { in gatt_find_bg_dev()
1329 auto& list = gatt_cb.bgconn_dev; in gatt_find_bg_dev_it()
1356 gatt_cb.bgconn_dev.emplace_back(); in gatt_add_bg_dev_list()
1357 tGATT_BG_CONN_DEV& dev = gatt_cb.bgconn_dev.back(); in gatt_add_bg_dev_list()
1377 if (dev_it == gatt_cb.bgconn_dev.end()) return false; in gatt_clear_bg_dev_for_addr()
1380 gatt_cb.bgconn_dev.erase(dev_it); in gatt_clear_bg_dev_for_addr()
1390 if (dev_it == gatt_cb.bgconn_dev.end()) return false; in gatt_remove_bg_dev_from_list()
1398 gatt_cb.bgconn_dev.erase(dev_it); in gatt_remove_bg_dev_from_list()
1403 auto it = gatt_cb.bgconn_dev.begin(); in gatt_deregister_bgdev_list()
1404 auto end = gatt_cb.bgconn_dev.end(); in gatt_deregister_bgdev_list()
1414 it = gatt_cb.bgconn_dev.erase(it); in gatt_deregister_bgdev_list()
1427 void gatt_reset_bgdev_list(void) { gatt_cb.bgconn_dev.clear(); } in gatt_reset_bgdev_list()