CVSROOT: /cvs Module name: src Changes by: d...@cvs.openbsd.org 2025/06/16 19:35:07
Modified files: sys/netinet : tcp_var.h Log message: guard tcp stat updates with splnet now that interrupts can update them. some tcp stack lso/tso statistics are now updated by drivers that implement tso/lro, and this code can run from an interrupt handler. eg, ifq_restart from a transmit completion interrupt can call a drivers start routine, which can preempt the tcp stack running on behalf of a system call. the tcp stats are per cpu counters so they can be updated without coordinating with each other, but, as per the counters manpage, updates on a cpu have to be serialised. this is to prevent corruption of at least the generation number each cpu uses to version the counter updates. since all the tcp stats are a single set of counters, any update has to prevent preemption. ok claudio@ bluhm@