Re: [PATCH net v2] net/sched: sch_netem: prevent packet length underflow with negative overhead
From: Bui Viet Dung
Date: Tue Oct 13 2026 - 10:26:36 EST
Hi,
Thanks for the detailed review. Both points are valid and critical:
1. mul_u64_u64_div_u64() on x86-64 uses 'divq' without overflow handling,
which raises a #DE divide exception when (len * NSEC_PER_SEC) / rate
overflows u64.
2. Returning S64_MAX can overflow the subsequent 'now + delay' addition in
netem_enqueue().
I will retract v2 and prepare a proper v3.
pw-bot: cr