Lines Matching refs:l2cb
59 tL2C_LCB* p_lcb = &l2cb.lcb_pool[0]; in l2cu_allocate_lcb()
74 p_lcb->idle_timeout = l2cb.idle_timeout; in l2cu_allocate_lcb()
87 l2cb.num_ble_links_active++; in l2cu_allocate_lcb()
90 l2cb.num_used_lcbs++; in l2cu_allocate_lcb()
166 l2cb.controller_le_xmit_window += p_lcb->sent_not_acked; in l2cu_release_lcb()
167 if (l2cb.controller_le_xmit_window > l2cb.num_lm_ble_bufs) { in l2cu_release_lcb()
168 l2cb.controller_le_xmit_window = l2cb.num_lm_ble_bufs; in l2cu_release_lcb()
171 l2cb.controller_xmit_window += p_lcb->sent_not_acked; in l2cu_release_lcb()
172 if (l2cb.controller_xmit_window > l2cb.num_lm_acl_bufs) { in l2cu_release_lcb()
173 l2cb.controller_xmit_window = l2cb.num_lm_acl_bufs; in l2cu_release_lcb()
204 if (l2cb.num_ble_links_active >= 1) l2cb.num_ble_links_active--; in l2cu_release_lcb()
208 if (l2cb.num_used_lcbs >= 1) l2cb.num_used_lcbs--; in l2cu_release_lcb()
241 tL2C_LCB* p_lcb = &l2cb.lcb_pool[0]; in l2cu_find_lcb_by_bd_addr()
311 UINT16_TO_STREAM(p, p_lcb->Handle() | l2cb.non_flushable_pbf); in l2cu_build_header()
1059 (l2cb.test_info_resp & in l2cu_send_peer_info_rsp()
1092 (l2cb.test_info_resp & in l2cu_send_peer_info_rsp()
1108 UINT32_TO_STREAM(p, l2cb.test_info_resp); in l2cu_send_peer_info_rsp()
1132 if (l2cb.fixed_reg[xx].pL2CA_FixedConn_Cb != NULL) in l2cu_send_peer_info_rsp()
1353 if (!l2cb.p_free_ccb_first) { in l2cu_allocate_ccb()
1360 p_ccb = l2cb.p_free_ccb_first; in l2cu_allocate_ccb()
1361 l2cb.p_free_ccb_first = p_ccb->p_next_ccb; in l2cu_allocate_ccb()
1365 p_ccb = &l2cb.ccb_pool[cid - L2CAP_BASE_APPL_CID]; in l2cu_allocate_ccb()
1367 if (p_ccb == l2cb.p_free_ccb_first) { in l2cu_allocate_ccb()
1368 l2cb.p_free_ccb_first = p_ccb->p_next_ccb; in l2cu_allocate_ccb()
1370 for (p_prev = l2cb.p_free_ccb_first; p_prev != nullptr; in l2cu_allocate_ccb()
1375 if (p_ccb == l2cb.p_free_ccb_last) { in l2cu_allocate_ccb()
1376 l2cb.p_free_ccb_last = p_prev; in l2cu_allocate_ccb()
1394 p_ccb->local_cid = L2CAP_BASE_APPL_CID + (uint16_t)(p_ccb - l2cb.ccb_pool); in l2cu_allocate_ccb()
1564 if (!l2cb.p_free_ccb_first) { in l2cu_release_ccb()
1565 l2cb.p_free_ccb_first = p_ccb; in l2cu_release_ccb()
1566 l2cb.p_free_ccb_last = p_ccb; in l2cu_release_ccb()
1571 p_ccb->p_prev_ccb = l2cb.p_free_ccb_last; in l2cu_release_ccb()
1572 l2cb.p_free_ccb_last->p_next_ccb = p_ccb; in l2cu_release_ccb()
1573 l2cb.p_free_ccb_last = p_ccb; in l2cu_release_ccb()
1642 tL2C_RCB* p_rcb = &l2cb.rcb_pool[0]; in l2cu_allocate_rcb()
1668 tL2C_RCB* p_rcb = &l2cb.ble_rcb_pool[0]; in l2cu_allocate_ble_rcb()
1752 tL2C_RCB* p_rcb = &l2cb.rcb_pool[0]; in l2cu_find_rcb_by_psm()
1774 tL2C_RCB* p_rcb = &l2cb.ble_rcb_pool[0]; in l2cu_find_ble_rcb_by_psm()
2032 tL2C_LCB* p_lcb = &l2cb.lcb_pool[0]; in l2cu_device_reset()
2059 tL2C_LCB* p_lcb_cur = &l2cb.lcb_pool[0]; in l2cu_create_conn_br_edr()
2105 tL2C_LCB* p_lcb = &l2cb.lcb_pool[0]; in l2cu_get_num_hi_priority()
2147 tL2C_LCB* p_lcb = &l2cb.lcb_pool[0]; in l2cu_find_lcb_by_state()
2177 p_lcb = &l2cb.lcb_pool[0]; in l2cu_lcb_disconnecting()
2275 l2cb.non_flushable_pbf = in l2cu_set_non_flushable_pbf()
2278 l2cb.non_flushable_pbf = (L2CAP_PKT_START << L2CAP_PKT_TYPE_SHIFT); in l2cu_set_non_flushable_pbf()
2320 for (xx = 0, p_lcb = &l2cb.lcb_pool[0]; xx < MAX_L2CAP_LINKS; in l2cu_resubmit_pending_sec_req()
2344 void l2cu_set_info_rsp_mask(uint32_t mask) { l2cb.test_info_resp = mask; } in l2cu_set_info_rsp_mask()
2438 l2cb.fixed_reg[fixed_cid - L2CAP_FIRST_FIXED_CHNL].default_idle_tout; in l2cu_initialize_fixed_ccb()
2528 p_lcb->peer_chnl_mask[0] = l2cb.l2c_ble_fixed_chnls_mask; in l2cu_process_fixed_chnl_resp()
2545 if (!l2cb.fixed_reg[xx].pL2CA_FixedConn_Cb) continue; in l2cu_process_fixed_chnl_resp()
2550 (*l2cb.fixed_reg[xx].pL2CA_FixedConn_Cb)( in l2cu_process_fixed_chnl_resp()
2553 (*l2cb.fixed_reg[xx].pL2CA_FixedConn_Cb)( in l2cu_process_fixed_chnl_resp()
2590 (*l2cb.fixed_reg[xx].pL2CA_FixedConn_Cb)( in l2cu_process_fixed_disc_cback()
2595 (l2cb.fixed_reg[xx].pL2CA_FixedConn_Cb != NULL)) in l2cu_process_fixed_disc_cback()
2596 (*l2cb.fixed_reg[xx].pL2CA_FixedConn_Cb)( in l2cu_process_fixed_disc_cback()
3120 tL2C_LCB* p_lcb = &l2cb.lcb_pool[0]; in l2cu_find_lcb_by_handle()
3151 p_ccb = l2cb.ccb_pool + local_cid; in l2cu_find_ccb_by_cid()
3200 UINT16_TO_STREAM(p, p_ccb->p_lcb->Handle() | l2cb.non_flushable_pbf); in l2cu_set_acl_hci_header()
3228 if (status == false) l2cb.is_cong_cback_context = true; in send_congestion_status_to_all_clients()
3232 if (status == false) l2cb.is_cong_cback_context = false; in send_congestion_status_to_all_clients()
3237 if (l2cb.fixed_reg[xx].pL2CA_FixedCong_Cb != NULL) in send_congestion_status_to_all_clients()
3238 (*l2cb.fixed_reg[xx].pL2CA_FixedCong_Cb)(p_ccb->p_lcb->remote_bd_addr, in send_congestion_status_to_all_clients()