diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2018-01-09 02:38:03 +0100 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2018-01-10 15:32:08 +0100 |
commit | 36596dadf54a920d26286cf9f421fb4ef648b51f (patch) | |
tree | e9e5cdd54acb21f0ccfa88c851bb7f6418bc4609 /net/netfilter/nft_meta.c | |
parent | netfilter: nf_tables: remove struct nft_af_info parameter in nf_tables_chain_type_lookup() (diff) | |
download | linux-dev-36596dadf54a920d26286cf9f421fb4ef648b51f.tar.xz linux-dev-36596dadf54a920d26286cf9f421fb4ef648b51f.zip |
netfilter: nf_tables: add single table list for all families
Place all existing user defined tables in struct net *, instead of
having one list per family. This saves us from one level of indentation
in netlink dump functions.
Place pointer to struct nft_af_info in struct nft_table temporarily, as
we still need this to put back reference module reference counter on
table removal.
This patch comes in preparation for the removal of struct nft_af_info.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'net/netfilter/nft_meta.c')
-rw-r--r-- | net/netfilter/nft_meta.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/net/netfilter/nft_meta.c b/net/netfilter/nft_meta.c index 1a91e676f13e..8fb91940e2e7 100644 --- a/net/netfilter/nft_meta.c +++ b/net/netfilter/nft_meta.c @@ -339,7 +339,7 @@ static int nft_meta_get_validate(const struct nft_ctx *ctx, if (priv->key != NFT_META_SECPATH) return 0; - switch (ctx->afi->family) { + switch (ctx->family) { case NFPROTO_NETDEV: hooks = 1 << NF_NETDEV_INGRESS; break; @@ -370,7 +370,7 @@ int nft_meta_set_validate(const struct nft_ctx *ctx, if (priv->key != NFT_META_PKTTYPE) return 0; - switch (ctx->afi->family) { + switch (ctx->family) { case NFPROTO_BRIDGE: hooks = 1 << NF_BR_PRE_ROUTING; break; |