ruleset: reduce ksoftirqd load by refering to looopback by numeric id
authorAndris PE <neandris@gmail.com>
Tue, 19 Sep 2023 15:23:59 +0000 (18:23 +0300)
committerJo-Philipp Wich <jo@mein.io>
Fri, 3 Nov 2023 13:11:06 +0000 (14:11 +0100)
commita5553dae70439c7e4fa910490fcf12a1ffff5bd2
treec3f1e6080c8295647157ddc589eaf71d09caeb36
parent19a8caf614ec338513e58535ea02c6ee52988170
ruleset: reduce ksoftirqd load by refering to looopback by numeric id

Reduce ksoftirq load by half using more efficient reference to loopback
which always has index equal to one.

Should help a lot with openwrt/openwrt#12914, openwrt/openwrt#12121 and
similar iperf3 cases clamping against 100% CPU usage.

Signed-off-by: Andris PE <neandris@gmail.com>
[fix S-o-b tag, fix commit author, rewrap commit message]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
30 files changed:
root/usr/share/firewall4/templates/ruleset.uc
tests/01_configuration/01_ruleset
tests/01_configuration/02_rule_order
tests/02_zones/01_policies
tests/02_zones/02_masq
tests/02_zones/03_masq_src_dest_restrictions
tests/02_zones/04_masq_allow_invalid
tests/02_zones/04_wildcard_devices
tests/02_zones/05_subnet_mask_matches
tests/02_zones/06_family_selections
tests/02_zones/07_helpers
tests/03_rules/01_direction
tests/03_rules/02_enabled
tests/03_rules/03_constraints
tests/03_rules/04_icmp
tests/03_rules/05_mangle
tests/03_rules/06_subnet_mask_matches
tests/03_rules/07_redirect
tests/03_rules/08_family_inheritance
tests/03_rules/09_time
tests/03_rules/10_notrack
tests/03_rules/11_log
tests/03_rules/12_mark
tests/04_forwardings/01_family_selections
tests/05_ipsets/01_declaration
tests/05_ipsets/02_usage
tests/06_includes/01_nft_includes
tests/06_includes/02_firewall.user_include
tests/06_includes/04_disabled_include
tests/06_includes/05_automatic_includes