[PATCH net v2 0/2] net: sched: act_gate: fix update races and infoleak

Paul Moses posted 2 patches 2 weeks, 4 days ago
[PATCH net v2 0/2] net: sched: act_gate: fix update races and infoleak
Posted by Paul Moses 2 weeks, 4 days ago
This series fixes act_gate schedule update races by switching to a
prepare-then-swap model with an RCU-protected params pointer, so the
hrtimer/datapath never observe partially updated or freed schedules.
Old params are freed via call_rcu() after the swap.

It also zero-initializes the netlink dump struct to prevent padding
information leaks, and tightens schedule/timing validation to avoid
misprogramming the hrtimer on invalid inputs.

Changes since v1:
- Drop tc-testing changes; no test updates required
- Validation fixes: base/cycle range checks + derived cycle overflow guard
- Fix create/update corner cases: avoid oldp deref on create, publish params
  only after full init, fix partial schedule copy cleanup
- Timer handling: cancel/reprogram only when required
- Keep dump struct zero-init without unrelated code motion

Patches:
 1/2 net/sched: act_gate: fix schedule updates with RCU swap
 2/2 net/sched: act_gate: zero-initialize netlink dump struct

--
2.52.GIT