Lines Matching refs:llcp_cb
57 BE_STREAM_TO_UINT8 (llcp_cb.lcb.peer_version, p); in llcp_util_parse_link_params()
58 LLCP_TRACE_DEBUG1 ("Peer Version - 0x%02X", llcp_cb.lcb.peer_version); in llcp_util_parse_link_params()
63 BE_STREAM_TO_UINT16 (llcp_cb.lcb.peer_miu, p); in llcp_util_parse_link_params()
64 llcp_cb.lcb.peer_miu &= LLCP_MIUX_MASK; in llcp_util_parse_link_params()
65 llcp_cb.lcb.peer_miu += LLCP_DEFAULT_MIU; in llcp_util_parse_link_params()
66 LLCP_TRACE_DEBUG1 ("Peer MIU - %d bytes", llcp_cb.lcb.peer_miu); in llcp_util_parse_link_params()
71 BE_STREAM_TO_UINT16 (llcp_cb.lcb.peer_wks, p); in llcp_util_parse_link_params()
72 LLCP_TRACE_DEBUG1 ("Peer WKS - 0x%04X", llcp_cb.lcb.peer_wks); in llcp_util_parse_link_params()
77 BE_STREAM_TO_UINT8 (llcp_cb.lcb.peer_lto, p); in llcp_util_parse_link_params()
78 llcp_cb.lcb.peer_lto *= LLCP_LTO_UNIT; /* 10ms unit */ in llcp_util_parse_link_params()
79 LLCP_TRACE_DEBUG1 ("Peer LTO - %d ms", llcp_cb.lcb.peer_lto); in llcp_util_parse_link_params()
84 BE_STREAM_TO_UINT8 (llcp_cb.lcb.peer_opt, p); in llcp_util_parse_link_params()
85 LLCP_TRACE_DEBUG1 ("Peer OPT - 0x%02X", llcp_cb.lcb.peer_opt); in llcp_util_parse_link_params()
118 if (llcp_cb.num_logical_data_link) in llcp_util_adjust_ll_congestion()
120 llcp_cb.ll_tx_congest_start = llcp_cb.max_num_ll_tx_buff / llcp_cb.num_logical_data_link; in llcp_util_adjust_ll_congestion()
121 llcp_cb.ll_rx_congest_start = llcp_cb.max_num_ll_rx_buff / llcp_cb.num_logical_data_link; in llcp_util_adjust_ll_congestion()
125 llcp_cb.ll_tx_congest_start = llcp_cb.max_num_ll_tx_buff; in llcp_util_adjust_ll_congestion()
126 llcp_cb.ll_rx_congest_start = llcp_cb.max_num_ll_rx_buff; in llcp_util_adjust_ll_congestion()
130 if (llcp_cb.ll_tx_congest_start == 0) in llcp_util_adjust_ll_congestion()
132 llcp_cb.ll_tx_congest_start = 1; in llcp_util_adjust_ll_congestion()
134 if (llcp_cb.ll_rx_congest_start == 0) in llcp_util_adjust_ll_congestion()
136 llcp_cb.ll_rx_congest_start = 1; in llcp_util_adjust_ll_congestion()
139 if (llcp_cb.ll_tx_congest_start > 1) in llcp_util_adjust_ll_congestion()
141 llcp_cb.ll_tx_congest_end = 1; in llcp_util_adjust_ll_congestion()
145 llcp_cb.ll_tx_congest_end = 0; in llcp_util_adjust_ll_congestion()
149 llcp_cb.num_logical_data_link, in llcp_util_adjust_ll_congestion()
150 llcp_cb.ll_tx_congest_start, in llcp_util_adjust_ll_congestion()
151 llcp_cb.ll_tx_congest_end, in llcp_util_adjust_ll_congestion()
152 llcp_cb.ll_rx_congest_start); in llcp_util_adjust_ll_congestion()
168 if (llcp_cb.num_data_link_connection) in llcp_util_adjust_dl_rx_congestion()
170 rx_congest_start = llcp_cb.num_rx_buff / llcp_cb.num_data_link_connection; in llcp_util_adjust_dl_rx_congestion()
174 if (llcp_cb.dlcb[idx].state == LLCP_DLC_STATE_CONNECTED) in llcp_util_adjust_dl_rx_congestion()
176 if (rx_congest_start > llcp_cb.dlcb[idx].local_rw) in llcp_util_adjust_dl_rx_congestion()
182 if (llcp_cb.dlcb[idx].local_rw + 1 > LLCP_DL_MIN_RX_CONGEST) in llcp_util_adjust_dl_rx_congestion()
183 llcp_cb.dlcb[idx].rx_congest_threshold = llcp_cb.dlcb[idx].local_rw + 1; in llcp_util_adjust_dl_rx_congestion()
185 llcp_cb.dlcb[idx].rx_congest_threshold = LLCP_DL_MIN_RX_CONGEST; in llcp_util_adjust_dl_rx_congestion()
189 llcp_cb.dlcb[idx].rx_congest_threshold = LLCP_DL_MIN_RX_CONGEST; in llcp_util_adjust_dl_rx_congestion()
194 llcp_cb.dlcb[idx].local_rw, in llcp_util_adjust_dl_rx_congestion()
195 llcp_cb.dlcb[idx].rx_congest_threshold); in llcp_util_adjust_dl_rx_congestion()
215 if (llcp_cb.overall_rx_congested) in llcp_util_check_rx_congested_status()
218 if (llcp_cb.total_rx_ui_pdu + llcp_cb.total_rx_i_pdu <= llcp_cb.overall_rx_congest_end) in llcp_util_check_rx_congested_status()
221 llcp_cb.total_rx_ui_pdu, llcp_cb.total_rx_i_pdu, in llcp_util_check_rx_congested_status()
222 llcp_cb.overall_rx_congest_end); in llcp_util_check_rx_congested_status()
224 llcp_cb.overall_rx_congested = FALSE; in llcp_util_check_rx_congested_status()
229 if ( (llcp_cb.dlcb[idx].state == LLCP_DLC_STATE_CONNECTED) in llcp_util_check_rx_congested_status()
230 &&(llcp_cb.dlcb[idx].is_rx_congested == FALSE) ) in llcp_util_check_rx_congested_status()
232 llcp_cb.dlcb[idx].flags |= LLCP_DATA_LINK_FLAG_PENDING_RR_RNR; in llcp_util_check_rx_congested_status()
240 if (llcp_cb.total_rx_ui_pdu + llcp_cb.total_rx_i_pdu >= llcp_cb.overall_rx_congest_start) in llcp_util_check_rx_congested_status()
243 llcp_cb.total_rx_ui_pdu, llcp_cb.total_rx_i_pdu, in llcp_util_check_rx_congested_status()
244 llcp_cb.overall_rx_congest_start); in llcp_util_check_rx_congested_status()
246 llcp_cb.overall_rx_congested = TRUE; in llcp_util_check_rx_congested_status()
251 if ( (llcp_cb.dlcb[idx].state == LLCP_DLC_STATE_CONNECTED) in llcp_util_check_rx_congested_status()
252 &&(llcp_cb.dlcb[idx].is_rx_congested == FALSE) ) in llcp_util_check_rx_congested_status()
254 llcp_cb.dlcb[idx].flags |= LLCP_DATA_LINK_FLAG_PENDING_RR_RNR; in llcp_util_check_rx_congested_status()
282 llcp_cb.total_tx_ui_pdu++; in llcp_util_send_ui()
287 ||(p_app_cb->ui_xmit_q.count >= llcp_cb.ll_tx_congest_start) in llcp_util_send_ui()
288 ||(llcp_cb.overall_tx_congested) in llcp_util_send_ui()
289 ||(llcp_cb.total_tx_ui_pdu >= llcp_cb.max_num_ll_tx_buff) ) in llcp_util_send_ui()
328 GKI_enqueue (&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_disc()
352 if (llcp_cb.dlcb[idx].state == LLCP_DLC_STATE_IDLE) in llcp_util_allocate_data_link()
354 p_dlcb = &(llcp_cb.dlcb[idx]); in llcp_util_allocate_data_link()
373 llcp_cb.num_data_link_connection++; in llcp_util_allocate_data_link()
376 … p_dlcb->local_sap, p_dlcb->remote_sap, llcp_cb.num_data_link_connection); in llcp_util_allocate_data_link()
403 if (llcp_cb.num_data_link_connection > 0) in llcp_util_deallocate_data_link()
405 llcp_cb.num_data_link_connection--; in llcp_util_deallocate_data_link()
408 …UG1 ("llcp_util_deallocate_data_link (): num_data_link_connection = %d", llcp_cb.num_data_link_con… in llcp_util_deallocate_data_link()
474 GKI_enqueue (&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_connect()
619 GKI_enqueue (&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_cc()
711 GKI_enqueue (&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_dm()
740 ||(llcp_cb.overall_rx_congested) ) in llcp_util_build_info_pdu()
781 GKI_enqueue (&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_frmr()
824 ||(llcp_cb.overall_rx_congested) ) in llcp_util_send_rr_rnr()
834 ||(llcp_cb.overall_rx_congested) ) in llcp_util_send_rr_rnr()
837 … p_dlcb->local_busy, p_dlcb->is_rx_congested, llcp_cb.overall_rx_congested); in llcp_util_send_rr_rnr()
874 GKI_enqueue (&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_rr_rnr()
900 p_app_cb = &llcp_cb.wks_cb[local_sap]; in llcp_util_get_app_cb()
907 p_app_cb = &llcp_cb.server_cb[local_sap - LLCP_LOWER_BOUND_SDP_SAP]; in llcp_util_get_app_cb()
914 p_app_cb = &llcp_cb.client_cb[local_sap - LLCP_LOWER_BOUND_LOCAL_SAP]; in llcp_util_get_app_cb()