• Home
  • Raw
  • Download

Lines Matching refs:fcrb

175     if (p_ccb->fcrb.wait_ack)  in l2c_fcr_start_timer()
185 if (p_ccb->fcrb.mon_retrans_timer.in_use == 0) in l2c_fcr_start_timer()
186 …btu_start_quick_timer (&p_ccb->fcrb.mon_retrans_timer, BTU_TTYPE_L2CAP_CHNL, tout*QUICK_TIMER_TICK… in l2c_fcr_start_timer()
201 if (p_ccb->fcrb.mon_retrans_timer.in_use) in l2c_fcr_stop_timer()
203 btu_stop_quick_timer (&p_ccb->fcrb.mon_retrans_timer); in l2c_fcr_stop_timer()
219 tL2C_FCRB *p_fcrb = &p_ccb->fcrb; in l2c_fcr_cleanup()
236 btu_stop_quick_timer (&p_ccb->fcrb.mon_retrans_timer); in l2c_fcr_cleanup()
241 UINT32 dur = GKI_get_os_tick_count() - p_ccb->fcrb.connect_tick_count; in l2c_fcr_cleanup()
250 …p_ccb->fcrb.pkts_retransmitted, p_ccb->fcrb.xmit_window_closed, p_ccb->fcrb.retrans_touts, p_ccb-> in l2c_fcr_cleanup()
252 …here is less than 2 packets in controller when flow controlled:%08u", p_ccb->fcrb.controller_idle); in l2c_fcr_cleanup()
254 …"max_held_acks:%08u, in_cfg.fcr.tx_win_sz:%08u", p_ccb->fcrb.max_held_acks, p_ccb->peer_cfg.fcr.tx… in l2c_fcr_cleanup()
258 p_ccb->fcrb.ertm_pkt_counts[0], p_ccb->fcrb.ertm_byte_counts[0], in l2c_fcr_cleanup()
259 (dur >= 10 ? (p_ccb->fcrb.ertm_byte_counts[0] * 100) / (dur / 10) : 0), in l2c_fcr_cleanup()
260 …p_ccb->fcrb.s_frames_sent[0], p_ccb->fcrb.s_frames_sent[1], p_ccb->fcrb.s_frames_sent[2], p_ccb->f… in l2c_fcr_cleanup()
265 p_ccb->fcrb.ertm_pkt_counts[1], p_ccb->fcrb.ertm_byte_counts[1], in l2c_fcr_cleanup()
266 (dur >= 10 ? (p_ccb->fcrb.ertm_byte_counts[1] * 100) / (dur / 10) : 0), in l2c_fcr_cleanup()
267 …p_ccb->fcrb.s_frames_rcvd[0], p_ccb->fcrb.s_frames_rcvd[1], p_ccb->fcrb.s_frames_rcvd[2], p_ccb->f… in l2c_fcr_cleanup()
277 if (i == p_ccb->fcrb.ack_delay_avg_index ) in l2c_fcr_cleanup()
285 i, p_ccb->fcrb.throughput[i], in l2c_fcr_cleanup()
286 … p_ccb->fcrb.ack_delay_avg[i], p_ccb->fcrb.ack_delay_min[i], p_ccb->fcrb.ack_delay_max[i], in l2c_fcr_cleanup()
287 … p_ccb->fcrb.ack_q_count_avg[i], p_ccb->fcrb.ack_q_count_min[i], p_ccb->fcrb.ack_q_count_max[i] ); in l2c_fcr_cleanup()
291 throughput_avg += p_ccb->fcrb.throughput[i]; in l2c_fcr_cleanup()
292 ack_delay_avg += p_ccb->fcrb.ack_delay_avg[i]; in l2c_fcr_cleanup()
293 ack_q_count_avg += p_ccb->fcrb.ack_q_count_avg[i]; in l2c_fcr_cleanup()
383 if ( (p_ccb->fcrb.remote_busy == TRUE) in l2c_fcr_is_flow_controlled()
384 || (GKI_queue_length(&p_ccb->fcrb.waiting_for_ack_q) >= p_ccb->peer_cfg.fcr.tx_win_sz) ) in l2c_fcr_is_flow_controlled()
389 p_ccb->fcrb.xmit_window_closed++; in l2c_fcr_is_flow_controlled()
392 p_ccb->fcrb.controller_idle++; in l2c_fcr_is_flow_controlled()
416 tL2C_FCRB *p_fcrb = &p_ccb->fcrb; in prepare_I_frame()
449 p_fcrb->last_ack_sent = p_ccb->fcrb.next_seq_expected; in prepare_I_frame()
451 if (p_ccb->fcrb.ack_timer.in_use) in prepare_I_frame()
452 btu_stop_quick_timer (&p_ccb->fcrb.ack_timer); in prepare_I_frame()
525 p_ccb->fcrb.s_frames_sent[function_code]++; in l2c_fcr_send_S_frame()
530 p_ccb->fcrb.wait_ack = TRUE; in l2c_fcr_send_S_frame()
538 ctrl_word |= (p_ccb->fcrb.next_seq_expected << L2CAP_FCR_REQ_SEQ_BITS_SHIFT); in l2c_fcr_send_S_frame()
598 p_ccb->fcrb.last_ack_sent = p_ccb->fcrb.next_seq_expected; in l2c_fcr_send_S_frame()
600 if (p_ccb->fcrb.ack_timer.in_use) in l2c_fcr_send_S_frame()
601 btu_stop_quick_timer (&p_ccb->fcrb.ack_timer); in l2c_fcr_send_S_frame()
686 … p_ccb->fcrb.next_tx_seq, p_ccb->fcrb.last_rx_ack, p_ccb->fcrb.next_seq_expected, in l2c_fcr_proc_pdu()
687 …p_ccb->fcrb.last_ack_sent, GKI_queue_length(&p_ccb->fcrb.waiting_for_ack_q), p_ccb->fcrb.num_tries… in l2c_fcr_proc_pdu()
717 if (p_ccb->fcrb.wait_ack) in l2c_fcr_proc_pdu()
724 if (p_ccb->fcrb.srej_sent) in l2c_fcr_proc_pdu()
726 else if (p_ccb->fcrb.local_busy) in l2c_fcr_proc_pdu()
735 …btu_start_quick_timer (&p_ccb->fcrb.mon_retrans_timer, BTU_TTYPE_L2CAP_CHNL, QUICK_TIMER_TICKS_PER… in l2c_fcr_proc_pdu()
741 p_ccb->fcrb.wait_ack = FALSE; in l2c_fcr_proc_pdu()
747 if (GKI_queue_is_empty(&p_ccb->fcrb.waiting_for_ack_q)) in l2c_fcr_proc_pdu()
748 p_ccb->fcrb.num_tries = 0; in l2c_fcr_proc_pdu()
776 …if ( (!p_ccb->fcrb.local_busy) && (!p_ccb->fcrb.srej_sent) && (!GKI_queue_is_empty(&p_ccb->fcrb.sr… in l2c_fcr_proc_pdu()
778 BUFFER_Q temp_q = p_ccb->fcrb.srej_rcv_hold_q; in l2c_fcr_proc_pdu()
780 GKI_init_q (&p_ccb->fcrb.srej_rcv_hold_q); in l2c_fcr_proc_pdu()
793 p_ccb->fcrb.next_seq_expected); in l2c_fcr_proc_pdu()
802 if (p_ccb->fcrb.rej_after_srej) in l2c_fcr_proc_pdu()
804 p_ccb->fcrb.rej_after_srej = FALSE; in l2c_fcr_proc_pdu()
805 p_ccb->fcrb.rej_sent = TRUE; in l2c_fcr_proc_pdu()
812 if ( (!p_ccb->fcrb.local_busy) && (!p_ccb->fcrb.rej_sent) && (!p_ccb->fcrb.srej_sent) in l2c_fcr_proc_pdu()
813 && (p_ccb->fcrb.next_seq_expected != p_ccb->fcrb.last_ack_sent) ) in l2c_fcr_proc_pdu()
818 …p_ccb->local_cid, p_ccb->fcrb.local_busy, p_ccb->fcrb.rej_sent, p_ccb->fcrb.srej_sent, p_ccb->fcrb in l2c_fcr_proc_pdu()
819 p_ccb->fcrb.last_ack_sent); in l2c_fcr_proc_pdu()
824 if ( (!GKI_queue_is_empty(&p_ccb->fcrb.retrans_q) || !GKI_queue_is_empty(&p_ccb->xmit_hold_q)) in l2c_fcr_proc_pdu()
825 && (p_ccb->fcrb.wait_ack == FALSE) in l2c_fcr_proc_pdu()
845 p_ccb->local_cid, p_ccb->fcrb.num_tries, p_ccb->peer_cfg.fcr.max_transmit, in l2c_fcr_proc_tout()
846 p_ccb->fcrb.wait_ack, GKI_queue_length(&p_ccb->fcrb.waiting_for_ack_q)); in l2c_fcr_proc_tout()
849 p_ccb->fcrb.retrans_touts++; in l2c_fcr_proc_tout()
852 …if ( (p_ccb->peer_cfg.fcr.max_transmit != 0) && (++p_ccb->fcrb.num_tries > p_ccb->peer_cfg.fcr.max… in l2c_fcr_proc_tout()
858 if (!p_ccb->fcrb.srej_sent && !p_ccb->fcrb.rej_sent) in l2c_fcr_proc_tout()
860 if (p_ccb->fcrb.local_busy) in l2c_fcr_proc_tout()
882 …p_ccb->chnl_state, p_ccb->fcrb.wait_ack, p_ccb->fcrb.next_seq_expected, p_ccb->fcrb.last_ack_sent); in l2c_fcr_proc_ack_tout()
884 if ( (p_ccb->chnl_state == CST_OPEN) && (!p_ccb->fcrb.wait_ack) in l2c_fcr_proc_ack_tout()
885 && (p_ccb->fcrb.last_ack_sent != p_ccb->fcrb.next_seq_expected) ) in l2c_fcr_proc_ack_tout()
888 p_ccb->fcrb.xmit_ack_touts++; in l2c_fcr_proc_ack_tout()
890 if (p_ccb->fcrb.local_busy) in l2c_fcr_proc_ack_tout()
910 tL2C_FCRB *p_fcrb = &p_ccb->fcrb; in process_reqseq()
966 if (!p_ccb->fcrb.wait_ack) in process_reqseq()
1002 tL2C_FCRB *p_fcrb = &p_ccb->fcrb; in process_s_frame()
1015 p_ccb->fcrb.s_frames_rcvd[s_frame_type]++; in process_s_frame()
1088 tL2C_FCRB *p_fcrb = &p_ccb->fcrb; in process_i_frame()
1102 p_ccb->fcrb.ertm_pkt_counts[1]++; in process_i_frame()
1103 p_ccb->fcrb.ertm_byte_counts[1] += p_buf->len; in process_i_frame()
1219 btu_stop_quick_timer (&p_ccb->fcrb.ack_timer); in process_i_frame()
1243 if ( (num_to_ack < p_ccb->fcrb.max_held_acks) && (!p_fcrb->local_busy) ) in process_i_frame()
1253 if (!p_ccb->fcrb.ack_timer.in_use) in process_i_frame()
1255 btu_start_quick_timer (&p_ccb->fcrb.ack_timer, BTU_TTYPE_L2CAP_FCR_ACK, in process_i_frame()
1260 && (GKI_queue_is_empty(&p_ccb->fcrb.srej_rcv_hold_q))) in process_i_frame()
1336 if (tx_seq != p_ccb->fcrb.next_seq_expected) in process_stream_frame()
1339 … p_ccb->local_cid, p_ccb->fcrb.next_seq_expected, tx_seq, p_ccb->fcrb.p_rx_sdu); in process_stream_frame()
1342 if (p_ccb->fcrb.p_rx_sdu != NULL) in process_stream_frame()
1344 GKI_freebuf (p_ccb->fcrb.p_rx_sdu); in process_stream_frame()
1345 p_ccb->fcrb.p_rx_sdu = NULL; in process_stream_frame()
1349 p_ccb->fcrb.next_seq_expected = (tx_seq + 1) & L2CAP_FCR_SEQ_MODULO; in process_stream_frame()
1354 if (p_ccb->fcrb.p_rx_sdu != NULL) in process_stream_frame()
1356 GKI_freebuf (p_ccb->fcrb.p_rx_sdu); in process_stream_frame()
1357 p_ccb->fcrb.p_rx_sdu = NULL; in process_stream_frame()
1377 tL2C_FCRB *p_fcrb = &p_ccb->fcrb; in do_sar_reassembly()
1510 if ( (GKI_getfirst(&p_ccb->fcrb.waiting_for_ack_q)) in retransmit_i_frames()
1512 && (p_ccb->fcrb.num_tries >= p_ccb->peer_cfg.fcr.max_transmit) ) in retransmit_i_frames()
1515 …p_ccb->fcrb.last_rx_ack, p_ccb->local_cid, p_ccb->fcrb.num_tries, p_ccb->peer_cfg.fcr.max_transmit, in retransmit_i_frames()
1516 GKI_queue_length(&p_ccb->fcrb.waiting_for_ack_q)); in retransmit_i_frames()
1527 …for (p_buf = (BT_HDR *)GKI_getfirst(&p_ccb->fcrb.waiting_for_ack_q); p_buf; p_buf = (BT_HDR *)GKI_… in retransmit_i_frames()
1544 …_frames() UNKNOWN seq: %u q_count: %u", tx_seq, GKI_queue_length(&p_ccb->fcrb.waiting_for_ack_q)); in retransmit_i_frames()
1565 while (!GKI_queue_is_empty(&p_ccb->fcrb.retrans_q)) in retransmit_i_frames()
1566 GKI_freebuf (GKI_dequeue (&p_ccb->fcrb.retrans_q)); in retransmit_i_frames()
1568 p_buf = (BT_HDR *)GKI_getfirst(&p_ccb->fcrb.waiting_for_ack_q); in retransmit_i_frames()
1579 GKI_enqueue (&p_ccb->fcrb.retrans_q, p_buf2); in retransmit_i_frames()
1590 if (GKI_queue_length(&p_ccb->fcrb.waiting_for_ack_q)) in retransmit_i_frames()
1592 p_ccb->fcrb.num_tries++; in retransmit_i_frames()
1623 if (GKI_getfirst(&p_ccb->fcrb.retrans_q)) in l2c_fcr_get_next_xmit_sdu_seg()
1625 p_buf = (BT_HDR *)GKI_dequeue (&p_ccb->fcrb.retrans_q); in l2c_fcr_get_next_xmit_sdu_seg()
1633 p_ccb->fcrb.pkts_retransmitted++; in l2c_fcr_get_next_xmit_sdu_seg()
1634 p_ccb->fcrb.ertm_pkt_counts[0]++; in l2c_fcr_get_next_xmit_sdu_seg()
1635 p_ccb->fcrb.ertm_byte_counts[0] += (p_buf->len - 8); in l2c_fcr_get_next_xmit_sdu_seg()
1748 GKI_enqueue (&p_ccb->fcrb.waiting_for_ack_q, p_xmit); in l2c_fcr_get_next_xmit_sdu_seg()
1763 GKI_enqueue (&p_ccb->fcrb.waiting_for_ack_q, p_wack); in l2c_fcr_get_next_xmit_sdu_seg()
1767 p_ccb->fcrb.ertm_pkt_counts[0]++; in l2c_fcr_get_next_xmit_sdu_seg()
1768 p_ccb->fcrb.ertm_byte_counts[0] += (p_xmit->len - 8); in l2c_fcr_get_next_xmit_sdu_seg()
2278 index = p_ccb->fcrb.ack_delay_avg_index; in l2c_fcr_collect_ack_delay()
2281 p_ccb->fcrb.ack_q_count_avg[index] += p_ccb->fcrb.waiting_for_ack_q.count; in l2c_fcr_collect_ack_delay()
2283 if ( p_ccb->fcrb.waiting_for_ack_q.count > p_ccb->fcrb.ack_q_count_max[index] ) in l2c_fcr_collect_ack_delay()
2284 p_ccb->fcrb.ack_q_count_max[index] = p_ccb->fcrb.waiting_for_ack_q.count; in l2c_fcr_collect_ack_delay()
2286 if ( p_ccb->fcrb.waiting_for_ack_q.count < p_ccb->fcrb.ack_q_count_min[index] ) in l2c_fcr_collect_ack_delay()
2287 p_ccb->fcrb.ack_q_count_min[index] = p_ccb->fcrb.waiting_for_ack_q.count; in l2c_fcr_collect_ack_delay()
2290 p_buf = (BT_HDR *)(p_ccb->fcrb.waiting_for_ack_q.p_first); in l2c_fcr_collect_ack_delay()
2294 p_ccb->fcrb.throughput[index] += p_buf->len - 8; in l2c_fcr_collect_ack_delay()
2308 p_ccb->fcrb.ack_delay_avg[index] += delay; in l2c_fcr_collect_ack_delay()
2309 if ( delay > p_ccb->fcrb.ack_delay_max[index] ) in l2c_fcr_collect_ack_delay()
2310 p_ccb->fcrb.ack_delay_max[index] = delay; in l2c_fcr_collect_ack_delay()
2311 if ( delay < p_ccb->fcrb.ack_delay_min[index] ) in l2c_fcr_collect_ack_delay()
2312 p_ccb->fcrb.ack_delay_min[index] = delay; in l2c_fcr_collect_ack_delay()
2318 p_ccb->fcrb.ack_delay_avg_count++; in l2c_fcr_collect_ack_delay()
2321 if (p_ccb->fcrb.ack_delay_avg_count > L2CAP_ERTM_STATS_AVG_NUM_SAMPLES) in l2c_fcr_collect_ack_delay()
2323 p_ccb->fcrb.ack_delay_avg_count = 0; in l2c_fcr_collect_ack_delay()
2325 p_ccb->fcrb.ack_q_count_avg[index] /= L2CAP_ERTM_STATS_AVG_NUM_SAMPLES; in l2c_fcr_collect_ack_delay()
2326 p_ccb->fcrb.ack_delay_avg[index] /= L2CAP_ERTM_STATS_AVG_NUM_SAMPLES; in l2c_fcr_collect_ack_delay()
2330 if (timestamp - p_ccb->fcrb.throughput_start > 0 ) in l2c_fcr_collect_ack_delay()
2331 p_ccb->fcrb.throughput[index] /= (timestamp - p_ccb->fcrb.throughput_start); in l2c_fcr_collect_ack_delay()
2333 p_ccb->fcrb.throughput_start = timestamp; in l2c_fcr_collect_ack_delay()
2336 index, p_ccb->fcrb.throughput[index], in l2c_fcr_collect_ack_delay()
2337 …p_ccb->fcrb.ack_delay_avg[index], p_ccb->fcrb.ack_delay_min[index], p_ccb->fcrb.ack_delay_max[inde… in l2c_fcr_collect_ack_delay()
2338 …p_ccb->fcrb.ack_q_count_avg[index], p_ccb->fcrb.ack_q_count_min[index], p_ccb->fcrb.ack_q_count_ma… in l2c_fcr_collect_ack_delay()
2343 p_ccb->fcrb.ack_delay_avg_index = index; in l2c_fcr_collect_ack_delay()
2345 p_ccb->fcrb.ack_q_count_max[index] = 0; in l2c_fcr_collect_ack_delay()
2346 p_ccb->fcrb.ack_q_count_min[index] = 0xFFFFFFFF; in l2c_fcr_collect_ack_delay()
2347 p_ccb->fcrb.ack_q_count_avg[index] = 0; in l2c_fcr_collect_ack_delay()
2350 p_ccb->fcrb.ack_delay_max[index] = 0; in l2c_fcr_collect_ack_delay()
2351 p_ccb->fcrb.ack_delay_min[index] = 0xFFFFFFFF; in l2c_fcr_collect_ack_delay()
2352 p_ccb->fcrb.ack_delay_avg[index] = 0; in l2c_fcr_collect_ack_delay()
2354 p_ccb->fcrb.throughput[index] = 0; in l2c_fcr_collect_ack_delay()