Lines Matching refs:llcp_cb
70 BE_STREAM_TO_UINT8(llcp_cb.lcb.peer_version, p); in llcp_util_parse_link_params()
72 << StringPrintf("Peer Version - 0x%02X", llcp_cb.lcb.peer_version); in llcp_util_parse_link_params()
81 BE_STREAM_TO_UINT16(llcp_cb.lcb.peer_miu, p); in llcp_util_parse_link_params()
82 llcp_cb.lcb.peer_miu &= LLCP_MIUX_MASK; in llcp_util_parse_link_params()
83 llcp_cb.lcb.peer_miu += LLCP_DEFAULT_MIU; in llcp_util_parse_link_params()
85 << StringPrintf("Peer MIU - %d bytes", llcp_cb.lcb.peer_miu); in llcp_util_parse_link_params()
94 BE_STREAM_TO_UINT16(llcp_cb.lcb.peer_wks, p); in llcp_util_parse_link_params()
96 << StringPrintf("Peer WKS - 0x%04X", llcp_cb.lcb.peer_wks); in llcp_util_parse_link_params()
105 BE_STREAM_TO_UINT8(llcp_cb.lcb.peer_lto, p); in llcp_util_parse_link_params()
106 llcp_cb.lcb.peer_lto *= LLCP_LTO_UNIT; /* 10ms unit */ in llcp_util_parse_link_params()
108 << StringPrintf("Peer LTO - %d ms", llcp_cb.lcb.peer_lto); in llcp_util_parse_link_params()
117 BE_STREAM_TO_UINT8(llcp_cb.lcb.peer_opt, p); in llcp_util_parse_link_params()
119 << StringPrintf("Peer OPT - 0x%02X", llcp_cb.lcb.peer_opt); in llcp_util_parse_link_params()
142 if (llcp_cb.num_logical_data_link) { in llcp_util_adjust_ll_congestion()
143 llcp_cb.ll_tx_congest_start = in llcp_util_adjust_ll_congestion()
144 llcp_cb.max_num_ll_tx_buff / llcp_cb.num_logical_data_link; in llcp_util_adjust_ll_congestion()
145 llcp_cb.ll_rx_congest_start = in llcp_util_adjust_ll_congestion()
146 llcp_cb.max_num_ll_rx_buff / llcp_cb.num_logical_data_link; in llcp_util_adjust_ll_congestion()
148 llcp_cb.ll_tx_congest_start = llcp_cb.max_num_ll_tx_buff; in llcp_util_adjust_ll_congestion()
149 llcp_cb.ll_rx_congest_start = llcp_cb.max_num_ll_rx_buff; in llcp_util_adjust_ll_congestion()
153 if (llcp_cb.ll_tx_congest_start == 0) { in llcp_util_adjust_ll_congestion()
154 llcp_cb.ll_tx_congest_start = 1; in llcp_util_adjust_ll_congestion()
156 if (llcp_cb.ll_rx_congest_start == 0) { in llcp_util_adjust_ll_congestion()
157 llcp_cb.ll_rx_congest_start = 1; in llcp_util_adjust_ll_congestion()
160 if (llcp_cb.ll_tx_congest_start > 1) { in llcp_util_adjust_ll_congestion()
161 llcp_cb.ll_tx_congest_end = 1; in llcp_util_adjust_ll_congestion()
163 llcp_cb.ll_tx_congest_end = 0; in llcp_util_adjust_ll_congestion()
169 llcp_cb.num_logical_data_link, llcp_cb.ll_tx_congest_start, in llcp_util_adjust_ll_congestion()
170 llcp_cb.ll_tx_congest_end, llcp_cb.ll_rx_congest_start); in llcp_util_adjust_ll_congestion()
185 if (llcp_cb.num_data_link_connection) { in llcp_util_adjust_dl_rx_congestion()
186 rx_congest_start = llcp_cb.num_rx_buff / llcp_cb.num_data_link_connection; in llcp_util_adjust_dl_rx_congestion()
189 if (llcp_cb.dlcb[idx].state == LLCP_DLC_STATE_CONNECTED) { in llcp_util_adjust_dl_rx_congestion()
190 if (rx_congest_start > llcp_cb.dlcb[idx].local_rw) { in llcp_util_adjust_dl_rx_congestion()
195 if (llcp_cb.dlcb[idx].local_rw + 1 > LLCP_DL_MIN_RX_CONGEST) in llcp_util_adjust_dl_rx_congestion()
196 llcp_cb.dlcb[idx].rx_congest_threshold = in llcp_util_adjust_dl_rx_congestion()
197 llcp_cb.dlcb[idx].local_rw + 1; in llcp_util_adjust_dl_rx_congestion()
199 llcp_cb.dlcb[idx].rx_congest_threshold = LLCP_DL_MIN_RX_CONGEST; in llcp_util_adjust_dl_rx_congestion()
201 llcp_cb.dlcb[idx].rx_congest_threshold = LLCP_DL_MIN_RX_CONGEST; in llcp_util_adjust_dl_rx_congestion()
206 llcp_cb.dlcb[idx].local_rw, llcp_cb.dlcb[idx].rx_congest_threshold); in llcp_util_adjust_dl_rx_congestion()
224 if (llcp_cb.overall_rx_congested) { in llcp_util_check_rx_congested_status()
226 if (llcp_cb.total_rx_ui_pdu + llcp_cb.total_rx_i_pdu <= in llcp_util_check_rx_congested_status()
227 llcp_cb.overall_rx_congest_end) { in llcp_util_check_rx_congested_status()
231 llcp_cb.total_rx_ui_pdu, llcp_cb.total_rx_i_pdu, in llcp_util_check_rx_congested_status()
232 llcp_cb.overall_rx_congest_end); in llcp_util_check_rx_congested_status()
234 llcp_cb.overall_rx_congested = false; in llcp_util_check_rx_congested_status()
238 if ((llcp_cb.dlcb[idx].state == LLCP_DLC_STATE_CONNECTED) && in llcp_util_check_rx_congested_status()
239 (llcp_cb.dlcb[idx].is_rx_congested == false)) { in llcp_util_check_rx_congested_status()
240 llcp_cb.dlcb[idx].flags |= LLCP_DATA_LINK_FLAG_PENDING_RR_RNR; in llcp_util_check_rx_congested_status()
246 if (llcp_cb.total_rx_ui_pdu + llcp_cb.total_rx_i_pdu >= in llcp_util_check_rx_congested_status()
247 llcp_cb.overall_rx_congest_start) { in llcp_util_check_rx_congested_status()
251 llcp_cb.total_rx_ui_pdu, llcp_cb.total_rx_i_pdu, in llcp_util_check_rx_congested_status()
252 llcp_cb.overall_rx_congest_start); in llcp_util_check_rx_congested_status()
254 llcp_cb.overall_rx_congested = true; in llcp_util_check_rx_congested_status()
258 if ((llcp_cb.dlcb[idx].state == LLCP_DLC_STATE_CONNECTED) && in llcp_util_check_rx_congested_status()
259 (llcp_cb.dlcb[idx].is_rx_congested == false)) { in llcp_util_check_rx_congested_status()
260 llcp_cb.dlcb[idx].flags |= LLCP_DATA_LINK_FLAG_PENDING_RR_RNR; in llcp_util_check_rx_congested_status()
288 llcp_cb.total_tx_ui_pdu++; in llcp_util_send_ui()
293 (p_app_cb->ui_xmit_q.count >= llcp_cb.ll_tx_congest_start) || in llcp_util_send_ui()
294 (llcp_cb.overall_tx_congested) || in llcp_util_send_ui()
295 (llcp_cb.total_tx_ui_pdu >= llcp_cb.max_num_ll_tx_buff)) { in llcp_util_send_ui()
333 GKI_enqueue(&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_disc()
355 if (llcp_cb.dlcb[idx].state == LLCP_DLC_STATE_IDLE) { in llcp_util_allocate_data_link()
356 p_dlcb = &(llcp_cb.dlcb[idx]); in llcp_util_allocate_data_link()
372 llcp_cb.num_data_link_connection++; in llcp_util_allocate_data_link()
378 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()
404 llcp_cb.num_data_link_connection--; in llcp_util_deallocate_data_link()
408 "num_data_link_connection = %d", llcp_cb.num_data_link_connection); in llcp_util_deallocate_data_link()
469 GKI_enqueue(&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_connect()
608 GKI_enqueue(&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_cc()
703 GKI_enqueue(&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_dm()
733 (llcp_cb.overall_rx_congested)) { in llcp_util_build_info_pdu()
772 GKI_enqueue(&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_frmr()
807 (llcp_cb.overall_rx_congested)) { in llcp_util_send_rr_rnr()
815 (llcp_cb.overall_rx_congested)) { in llcp_util_send_rr_rnr()
820 llcp_cb.overall_rx_congested); in llcp_util_send_rr_rnr()
854 GKI_enqueue(&llcp_cb.lcb.sig_xmit_q, p_msg); in llcp_util_send_rr_rnr()
875 p_app_cb = &llcp_cb.wks_cb[local_sap]; in llcp_util_get_app_cb()
879 p_app_cb = &llcp_cb.server_cb[local_sap - LLCP_LOWER_BOUND_SDP_SAP]; in llcp_util_get_app_cb()
883 p_app_cb = &llcp_cb.client_cb[local_sap - LLCP_LOWER_BOUND_LOCAL_SAP]; in llcp_util_get_app_cb()