]> git.itanic.dy.fi Git - linux-stable/commit
netfilter: nftables: add nft_parse_register_load() and use it
authorPablo Neira Ayuso <pablo@netfilter.org>
Tue, 16 May 2023 14:44:27 +0000 (16:44 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 30 May 2023 11:44:07 +0000 (12:44 +0100)
commit25336cd96b034de2c59af65cbbe17f6afb748371
treee93386f9e391a916467c0741e7a260359db942e9
parent116d53f09ff52e6f98e3fe1f85d8898d6ba26c68
netfilter: nftables: add nft_parse_register_load() and use it

4f16d25c68ec844299a4df6ecbb0234eaf88a935 ]

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

This update requires to replace:

enum nft_registers      sreg:8;

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

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

when passing the register field as reference.

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
25 files changed:
include/net/netfilter/nf_tables.h
include/net/netfilter/nf_tables_core.h
include/net/netfilter/nft_meta.h
net/ipv4/netfilter/nft_dup_ipv4.c
net/ipv6/netfilter/nft_dup_ipv6.c
net/netfilter/nf_tables_api.c
net/netfilter/nft_bitwise.c
net/netfilter/nft_byteorder.c
net/netfilter/nft_cmp.c
net/netfilter/nft_ct.c
net/netfilter/nft_dup_netdev.c
net/netfilter/nft_dynset.c
net/netfilter/nft_exthdr.c
net/netfilter/nft_fwd_netdev.c
net/netfilter/nft_hash.c
net/netfilter/nft_lookup.c
net/netfilter/nft_masq.c
net/netfilter/nft_meta.c
net/netfilter/nft_nat.c
net/netfilter/nft_objref.c
net/netfilter/nft_payload.c
net/netfilter/nft_queue.c
net/netfilter/nft_range.c
net/netfilter/nft_redir.c
net/netfilter/nft_tproxy.c