[BUG] net/sched: act_gate cycle time can wrap hrtimer expiry to zero
From: shaos
Date: Thu Oct 22 2026 - 10:51:33 EST
Hello,
An RTM_NEWACTION request installs act_gate with base_time=1, cycle_time=UINT64_MAX and one valid entry. The unchecked cycle arithmetic wraps the absolute timer deadline to zero; the hrtimer callback keeps restarting immediately and the add request never returns.
HEAD commit: c03c1a14507dfaf8b856c2608f9ac216021fc222
git tree: 30fd2ef82912c26cf3a58ad0ba6afc375fa851ac
source version: Linux 7.3.0, local master
compiler: gcc 11.4.0, GNU ld 2.38
console output:
https://gist.githubusercontent.com/shaos26/5393c0a25cccdd0b182a72de6d245c78/raw/3498a27c8537da1604402fd68c433e47de80f0dd/console-output.txt
kernel config:
https://gist.githubusercontent.com/shaos26/5393c0a25cccdd0b182a72de6d245c78/raw/e1458ab0ee43d1aa31991c1e3435cf9fee7635f4/kernel-config.txt
reproducer:
https://gist.githubusercontent.com/shaos26/5393c0a25cccdd0b182a72de6d245c78/raw/9cf01ec7c86d32377ec34a6fb0e6b4b214a5e931/poc.c
Build the tested kernel with the attached configuration and boot it in a disposable QEMU VM with softlockup reporting enabled. Compile poc.c statically and run as a process with initial-namespace CAP_NET_ADMIN. Do not run on a production system because the positive intentionally stalls a CPU.
Impact and prerequisites:
The watchdog reports a soft lockup and can panic the machine when softlockup_panic is enabled. This reproduction requires CAP_NET_ADMIN in the initial user namespace; it is a privileged denial of service, not an unprivileged escalation.
Validation: Two fresh positive boots reproduced the lockup. Near-maximum-cycle and patched-validation controls completed normally.
Thanks,
shaos