aboutsummaryrefslogtreecommitdiff
path: root/include/net
diff options
context:
space:
mode:
authorGravatar David S. Miller <davem@davemloft.net> 2021-04-27 15:32:54 -0700
committerGravatar David S. Miller <davem@davemloft.net> 2021-04-27 15:32:54 -0700
commit0711459095bc9ddb5a0086146d2751e6d5412cbf (patch)
tree0cf911953df3ca12f637f87ee7abcc8c01f8afb1 /include/net
parentnet: fix a concurrency bug in l2tp_tunnel_register() (diff)
parentnetfilter: nft_socket: fix build with CONFIG_SOCK_CGROUP_DATA=n (diff)
downloadlinux-0711459095bc9ddb5a0086146d2751e6d5412cbf.tar.gz
linux-0711459095bc9ddb5a0086146d2751e6d5412cbf.tar.bz2
linux-0711459095bc9ddb5a0086146d2751e6d5412cbf.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/pablo/nf-next
Pablo Neira Ayuso says: ==================== Netfilter updates for net-next The following patchset contains Netfilter updates for net-next: 1) Add support for the catch-all set element. This special element can be used to define a default action to be applied in case that the set lookup returns no matching element. 2) Fix incorrect #ifdef dependencies in the nftables cgroupsv2 support, from Arnd Bergmann. ==================== Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net')
-rw-r--r--include/net/netfilter/nf_tables.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/net/netfilter/nf_tables.h b/include/net/netfilter/nf_tables.h
index eb708b77c4a5..27eeb613bb4e 100644
--- a/include/net/netfilter/nf_tables.h
+++ b/include/net/netfilter/nf_tables.h
@@ -497,6 +497,7 @@ struct nft_set {
u8 dlen;
u8 num_exprs;
struct nft_expr *exprs[NFT_SET_EXPR_MAX];
+ struct list_head catchall_list;
unsigned char data[]
__attribute__((aligned(__alignof__(u64))));
};
@@ -522,6 +523,10 @@ struct nft_set *nft_set_lookup_global(const struct net *net,
const struct nlattr *nla_set_id,
u8 genmask);
+struct nft_set_ext *nft_set_catchall_lookup(const struct net *net,
+ const struct nft_set *set);
+void *nft_set_catchall_gc(const struct nft_set *set);
+
static inline unsigned long nft_set_gc_interval(const struct nft_set *set)
{
return set->gc_int ? msecs_to_jiffies(set->gc_int) : HZ;