]> git.dujemihanovic.xyz Git - linux.git/commit
netfilter: Remove the now superfluous sentinel elements from ctl_table array
authorJoel Granados <j.granados@samsung.com>
Wed, 1 May 2024 09:29:30 +0000 (11:29 +0200)
committerDavid S. Miller <davem@davemloft.net>
Fri, 3 May 2024 12:29:42 +0000 (13:29 +0100)
commit635470eb0aa71ba41c47593c66f65ac1e5d59dd7
tree07c989aa637e1352fd67a298d59dd266d033882c
parent73dbd8cf7947f7da47b23f4adc07593c4dc452b4
netfilter: Remove the now superfluous sentinel elements from ctl_table array

This commit comes at the tail end of a greater effort to remove the
empty elements at the end of the ctl_table arrays (sentinels) which will
reduce the overall build time size of the kernel and run time memory
bloat by ~64 bytes per sentinel (further information Link :
https://lore.kernel.org/all/ZO5Yx5JFogGi%2FcBo@bombadil.infradead.org/)

* Remove sentinel elements from ctl_table structs
* Remove instances where an array element is zeroed out to make it look
  like a sentinel. This is not longer needed and is safe after commit
  c899710fe7f9 ("networking: Update to register_net_sysctl_sz") added
  the array size to the ctl_table registration
* Remove the need for having __NF_SYSCTL_CT_LAST_SYSCTL as the
  sysctl array size is now in NF_SYSCTL_CT_LAST_SYSCTL
* Remove extra element in ctl_table arrays declarations

Acked-by: Kees Cook <keescook@chromium.org> # loadpin & yama
Signed-off-by: Joel Granados <j.granados@samsung.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/bridge/br_netfilter_hooks.c
net/ipv6/netfilter/nf_conntrack_reasm.c
net/netfilter/ipvs/ip_vs_ctl.c
net/netfilter/ipvs/ip_vs_lblc.c
net/netfilter/ipvs/ip_vs_lblcr.c
net/netfilter/nf_conntrack_standalone.c
net/netfilter/nf_log.c