netfilter: nf_conntrack: allow to register bridge support

This patch adds infrastructure to register and to unregister bridge
support for the conntrack module via nf_ct_bridge_register() and
nf_ct_bridge_unregister().

Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
Pablo Neira Ayuso
2019-05-29 13:25:36 +02:00
committed by David S. Miller
parent 19c3401a91
commit d035f19f59
3 changed files with 72 additions and 3 deletions

View File

@@ -49,6 +49,7 @@ union nf_conntrack_expect_proto {
struct nf_conntrack_net {
unsigned int users4;
unsigned int users6;
unsigned int users_bridge;
};
#include <linux/types.h>

View File

@@ -0,0 +1,13 @@
#ifndef NF_CONNTRACK_BRIDGE_
#define NF_CONNTRACK_BRIDGE_
struct nf_ct_bridge_info {
struct nf_hook_ops *ops;
unsigned int ops_size;
struct module *me;
};
void nf_ct_bridge_register(struct nf_ct_bridge_info *info);
void nf_ct_bridge_unregister(struct nf_ct_bridge_info *info);
#endif