mirror of
https://github.com/torvalds/linux.git
synced 2026-10-07 22:37:45 -04:00
Using "iptables -L" with a lot of rules have a too big BH latency. Jesper mentioned ~6 ms and worried of frame drops. Switch to a per_cpu seqlock scheme, so that taking a snapshot of counters doesnt need to block BH (for this cpu, but also other cpus). This adds two increments on seqlock sequence per ipt_do_table() call, its a reasonable cost for allowing "iptables -L" not block BH processing. Reported-by: Jesper Dangaard Brouer <[email protected]> Signed-off-by: Eric Dumazet <[email protected]> CC: Patrick McHardy <[email protected]> Acked-by: Stephen Hemminger <[email protected]> Acked-by: Jesper Dangaard Brouer <[email protected]> Signed-off-by: Pablo Neira Ayuso <[email protected]>