]> git.itanic.dy.fi Git - linux-stable/commit
netfilter: nftables: add nft_parse_register_store() and use it
authorPablo Neira Ayuso <pablo@netfilter.org>
Tue, 16 May 2023 15:06:06 +0000 (17:06 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 30 May 2023 11:42:12 +0000 (12:42 +0100)
commite1c59f90e1a6a7f4814c10eb324a9f3ec76031d9
tree2cfff95d0f1fa81bc6ffb765dec642c07a899f16
parente570ac195dc92d9366eb0877f637b2c4998627b2
netfilter: nftables: add nft_parse_register_store() and use it

345023b0db315648ccc3c1a36aee88304a8b4d91 ]

This new function combines the netlink register attribute parser
and the store validation function.

This update requires to replace:

        enum nft_registers      dreg:8;

in many of the expression private areas otherwise compiler complains
with:

        error: cannot take address of bit-field ‘dreg’

when passing the register field as reference.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
19 files changed:
include/net/netfilter/nf_tables.h
include/net/netfilter/nf_tables_core.h
include/net/netfilter/nft_fib.h
net/netfilter/nf_tables_api.c
net/netfilter/nft_bitwise.c
net/netfilter/nft_byteorder.c
net/netfilter/nft_ct.c
net/netfilter/nft_exthdr.c
net/netfilter/nft_fib.c
net/netfilter/nft_hash.c
net/netfilter/nft_immediate.c
net/netfilter/nft_lookup.c
net/netfilter/nft_meta.c
net/netfilter/nft_numgen.c
net/netfilter/nft_osf.c
net/netfilter/nft_payload.c
net/netfilter/nft_rt.c
net/netfilter/nft_socket.c
net/netfilter/nft_tunnel.c