Lines Matching refs:ack
19 int ossl_quic_frame_ack_contains_pn(const OSSL_QUIC_FRAME_ACK *ack, QUIC_PN pn) in OSSL_SAFE_MATH_UNSIGNED()
23 for (i = 0; i < ack->num_ack_ranges; ++i) in OSSL_SAFE_MATH_UNSIGNED()
24 if (pn >= ack->ack_ranges[i].start in OSSL_SAFE_MATH_UNSIGNED()
25 && pn <= ack->ack_ranges[i].end) in OSSL_SAFE_MATH_UNSIGNED()
57 const OSSL_QUIC_FRAME_ACK *ack) in ossl_quic_wire_encode_frame_ack() argument
59 uint64_t frame_type = ack->ecn_present ? OSSL_QUIC_FRAME_TYPE_ACK_WITH_ECN in ossl_quic_wire_encode_frame_ack()
63 uint64_t i, num_ack_ranges = ack->num_ack_ranges; in ossl_quic_wire_encode_frame_ack()
69 delay = ossl_time_divide(ossl_time_divide(ack->delay_time, OSSL_TIME_US), in ossl_quic_wire_encode_frame_ack()
73 largest_ackd = ack->ack_ranges[0].end; in ossl_quic_wire_encode_frame_ack()
74 first_ack_range = ack->ack_ranges[0].end - ack->ack_ranges[0].start; in ossl_quic_wire_encode_frame_ack()
86 gap = ack->ack_ranges[i - 1].start - ack->ack_ranges[i].end - 2; in ossl_quic_wire_encode_frame_ack()
87 range_len = ack->ack_ranges[i].end - ack->ack_ranges[i].start; in ossl_quic_wire_encode_frame_ack()
94 if (ack->ecn_present) in ossl_quic_wire_encode_frame_ack()
95 if (!WPACKET_quic_write_vlint(pkt, ack->ect0) in ossl_quic_wire_encode_frame_ack()
96 || !WPACKET_quic_write_vlint(pkt, ack->ect1) in ossl_quic_wire_encode_frame_ack()
97 || !WPACKET_quic_write_vlint(pkt, ack->ecnce)) in ossl_quic_wire_encode_frame_ack()
519 OSSL_QUIC_FRAME_ACK *ack, in ossl_quic_wire_decode_frame_ack() argument
541 if (ack != NULL) { in ossl_quic_wire_decode_frame_ack()
543 ack->delay_time in ossl_quic_wire_decode_frame_ack()
549 ack->delay_time = ossl_time_infinite(); in ossl_quic_wire_decode_frame_ack()
551 if (ack->num_ack_ranges > 0) { in ossl_quic_wire_decode_frame_ack()
552 ack->ack_ranges[0].end = largest_ackd; in ossl_quic_wire_decode_frame_ack()
553 ack->ack_ranges[0].start = start; in ossl_quic_wire_decode_frame_ack()
568 if (ack != NULL && i + 1 < ack->num_ack_ranges) { in ossl_quic_wire_decode_frame_ack()
569 ack->ack_ranges[i + 1].start = start = end - len; in ossl_quic_wire_decode_frame_ack()
570 ack->ack_ranges[i + 1].end = end; in ossl_quic_wire_decode_frame_ack()
574 if (ack != NULL && ack_range_count + 1 < ack->num_ack_ranges) in ossl_quic_wire_decode_frame_ack()
575 ack->num_ack_ranges = (size_t)ack_range_count + 1; in ossl_quic_wire_decode_frame_ack()
588 if (ack != NULL) { in ossl_quic_wire_decode_frame_ack()
589 ack->ect0 = ect0; in ossl_quic_wire_decode_frame_ack()
590 ack->ect1 = ect1; in ossl_quic_wire_decode_frame_ack()
591 ack->ecnce = ecnce; in ossl_quic_wire_decode_frame_ack()
592 ack->ecn_present = 1; in ossl_quic_wire_decode_frame_ack()
594 } else if (ack != NULL) { in ossl_quic_wire_decode_frame_ack()
595 ack->ecn_present = 0; in ossl_quic_wire_decode_frame_ack()