Re: [PATCH net-next v13 09/15] quic: add congestion control
Xin Long <[email protected]> Fri, 12 Jun 2026 15:37:33 -0400
| Newsgroups | dev.linux.lists.quic,dev.linux.lists.kernel-tls-handshake,org.kernel.vger.linux-cifs,org.kernel.vger.netdev |
|---|---|
| Message-ID | <CADvbK_c_qBNuad6HkYTZe0MpgMSbMdYSsSAz62DhEYaEapaCTg@mail.gmail.com> |
[sashiko-gemini] > + case QUIC_CONG_CONGESTION_AVOIDANCE: > + /* cong->window is never zero; it is initialized by > + * quic_packet_route() during connect/accept. > + */ > + cong->window += cong->mss * bytes / cong->window; Can this arithmetic permanently stall congestion window growth or cause an overflow? Since all variables are 32-bit integers, the division could truncate to 0 as the window grows larger than cong->mss * bytes. Also, if bytes is large due to coalesced ACKs, could the multiplication wrap around U32_MAX? This looks a legit one, will confirm and fix it. Thanks.