Lines Matching refs:fcrb
168 if (p_ccb->fcrb.wait_ack) { in l2c_fcr_start_timer()
175 if (!alarm_is_scheduled(p_ccb->fcrb.mon_retrans_timer)) { in l2c_fcr_start_timer()
176 alarm_set_on_mloop(p_ccb->fcrb.mon_retrans_timer, tout, in l2c_fcr_start_timer()
192 alarm_cancel(p_ccb->fcrb.mon_retrans_timer); in l2c_fcr_stop_timer()
207 tL2C_FCRB* p_fcrb = &p_ccb->fcrb; in l2c_fcr_cleanup()
269 if ((p_ccb->fcrb.remote_busy) || in l2c_fcr_is_flow_controlled()
270 (fixed_queue_length(p_ccb->fcrb.waiting_for_ack_q) >= in l2c_fcr_is_flow_controlled()
293 tL2C_FCRB* p_fcrb = &p_ccb->fcrb; in prepare_I_frame()
322 p_fcrb->last_ack_sent = p_ccb->fcrb.next_seq_expected; in prepare_I_frame()
324 alarm_cancel(p_ccb->fcrb.ack_timer); in prepare_I_frame()
395 p_ccb->fcrb.wait_ack = true; in l2c_fcr_send_S_frame()
403 ctrl_word |= (p_ccb->fcrb.next_seq_expected << L2CAP_FCR_REQ_SEQ_BITS_SHIFT); in l2c_fcr_send_S_frame()
453 p_ccb->fcrb.last_ack_sent = p_ccb->fcrb.next_seq_expected; in l2c_fcr_send_S_frame()
455 alarm_cancel(p_ccb->fcrb.ack_timer); in l2c_fcr_send_S_frame()
527 p_ccb->fcrb.next_tx_seq, p_ccb->fcrb.last_rx_ack, in l2c_fcr_proc_pdu()
528 p_ccb->fcrb.next_seq_expected, p_ccb->fcrb.last_ack_sent, in l2c_fcr_proc_pdu()
529 fixed_queue_length(p_ccb->fcrb.waiting_for_ack_q), p_ccb->fcrb.num_tries); in l2c_fcr_proc_pdu()
553 if (p_ccb->fcrb.wait_ack) { in l2c_fcr_proc_pdu()
558 if (p_ccb->fcrb.srej_sent) in l2c_fcr_proc_pdu()
571 alarm_set_on_mloop(p_ccb->fcrb.mon_retrans_timer, BT_1SEC_TIMEOUT_MS, in l2c_fcr_proc_pdu()
578 p_ccb->fcrb.wait_ack = false; in l2c_fcr_proc_pdu()
583 if (fixed_queue_is_empty(p_ccb->fcrb.waiting_for_ack_q)) in l2c_fcr_proc_pdu()
584 p_ccb->fcrb.num_tries = 0; in l2c_fcr_proc_pdu()
610 if ((!p_ccb->fcrb.srej_sent) && in l2c_fcr_proc_pdu()
611 (!fixed_queue_is_empty(p_ccb->fcrb.srej_rcv_hold_q))) { in l2c_fcr_proc_pdu()
612 fixed_queue_t* temp_q = p_ccb->fcrb.srej_rcv_hold_q; in l2c_fcr_proc_pdu()
613 p_ccb->fcrb.srej_rcv_hold_q = fixed_queue_new(SIZE_MAX); in l2c_fcr_proc_pdu()
627 p_ccb->fcrb.next_seq_expected); in l2c_fcr_proc_pdu()
636 if (p_ccb->fcrb.rej_after_srej) { in l2c_fcr_proc_pdu()
637 p_ccb->fcrb.rej_after_srej = false; in l2c_fcr_proc_pdu()
638 p_ccb->fcrb.rej_sent = true; in l2c_fcr_proc_pdu()
646 if ((!p_ccb->fcrb.rej_sent) && (!p_ccb->fcrb.srej_sent) && in l2c_fcr_proc_pdu()
647 (p_ccb->fcrb.next_seq_expected != p_ccb->fcrb.last_ack_sent)) in l2c_fcr_proc_pdu()
653 p_ccb->local_cid, 0, p_ccb->fcrb.rej_sent, p_ccb->fcrb.srej_sent, in l2c_fcr_proc_pdu()
654 p_ccb->fcrb.next_seq_expected, p_ccb->fcrb.last_ack_sent); in l2c_fcr_proc_pdu()
659 if ((!fixed_queue_is_empty(p_ccb->fcrb.retrans_q) || in l2c_fcr_proc_pdu()
661 (!p_ccb->fcrb.wait_ack) && (!l2c_fcr_is_flow_controlled(p_ccb))) { in l2c_fcr_proc_pdu()
787 p_ccb->local_cid, p_ccb->fcrb.num_tries, p_ccb->peer_cfg.fcr.max_transmit, in l2c_fcr_proc_tout()
788 p_ccb->fcrb.wait_ack, fixed_queue_length(p_ccb->fcrb.waiting_for_ack_q)); in l2c_fcr_proc_tout()
791 (++p_ccb->fcrb.num_tries > p_ccb->peer_cfg.fcr.max_transmit)) { in l2c_fcr_proc_tout()
794 if (!p_ccb->fcrb.srej_sent && !p_ccb->fcrb.rej_sent) { in l2c_fcr_proc_tout()
814 p_ccb->local_cid, p_ccb->chnl_state, p_ccb->fcrb.wait_ack, in l2c_fcr_proc_ack_tout()
815 p_ccb->fcrb.next_seq_expected, p_ccb->fcrb.last_ack_sent); in l2c_fcr_proc_ack_tout()
817 if ((p_ccb->chnl_state == CST_OPEN) && (!p_ccb->fcrb.wait_ack) && in l2c_fcr_proc_ack_tout()
818 (p_ccb->fcrb.last_ack_sent != p_ccb->fcrb.next_seq_expected)) { in l2c_fcr_proc_ack_tout()
834 tL2C_FCRB* p_fcrb = &p_ccb->fcrb; in process_reqseq()
891 if (!p_ccb->fcrb.wait_ack) l2c_fcr_stop_timer(p_ccb); in process_reqseq()
927 tL2C_FCRB* p_fcrb = &p_ccb->fcrb; in process_s_frame()
1004 tL2C_FCRB* p_fcrb = &p_ccb->fcrb; in process_i_frame()
1101 alarm_cancel(p_ccb->fcrb.ack_timer); in process_i_frame()
1129 if (num_to_ack < p_ccb->fcrb.max_held_acks) delay_ack = true; in process_i_frame()
1137 if (!alarm_is_scheduled(p_ccb->fcrb.ack_timer)) { in process_i_frame()
1138 alarm_set_on_mloop(p_ccb->fcrb.ack_timer, L2CAP_FCR_ACK_TIMEOUT_MS, in process_i_frame()
1143 fixed_queue_is_empty(p_ccb->fcrb.srej_rcv_hold_q)) { in process_i_frame()
1163 tL2C_FCRB* p_fcrb = &p_ccb->fcrb; in do_sar_reassembly()
1277 if ((!fixed_queue_is_empty(p_ccb->fcrb.waiting_for_ack_q)) && in retransmit_i_frames()
1279 (p_ccb->fcrb.num_tries >= p_ccb->peer_cfg.fcr.max_transmit)) { in retransmit_i_frames()
1283 p_ccb->fcrb.last_rx_ack, p_ccb->local_cid, p_ccb->fcrb.num_tries, in retransmit_i_frames()
1285 fixed_queue_length(p_ccb->fcrb.waiting_for_ack_q)); in retransmit_i_frames()
1295 if (!fixed_queue_is_empty(p_ccb->fcrb.waiting_for_ack_q)) { in retransmit_i_frames()
1296 list_ack = fixed_queue_get_list(p_ccb->fcrb.waiting_for_ack_q); in retransmit_i_frames()
1322 fixed_queue_length(p_ccb->fcrb.waiting_for_ack_q)); in retransmit_i_frames()
1341 while (!fixed_queue_is_empty(p_ccb->fcrb.retrans_q)) in retransmit_i_frames()
1342 osi_free(fixed_queue_try_dequeue(p_ccb->fcrb.retrans_q)); in retransmit_i_frames()
1356 fixed_queue_enqueue(p_ccb->fcrb.retrans_q, p_buf2); in retransmit_i_frames()
1365 if (fixed_queue_length(p_ccb->fcrb.waiting_for_ack_q)) { in retransmit_i_frames()
1366 p_ccb->fcrb.num_tries++; in retransmit_i_frames()
1396 p_buf = (BT_HDR*)fixed_queue_try_dequeue(p_ccb->fcrb.retrans_q); in l2c_fcr_get_next_xmit_sdu_seg()
1506 fixed_queue_enqueue(p_ccb->fcrb.waiting_for_ack_q, p_xmit); in l2c_fcr_get_next_xmit_sdu_seg()
1513 fixed_queue_enqueue(p_ccb->fcrb.waiting_for_ack_q, p_wack); in l2c_fcr_get_next_xmit_sdu_seg()