netfilter: nf_tables: allow chain type to override hook register
Will be used in followup patch when nat types no longer use nf_register_net_hook() but will instead register with the nat core. Signed-off-by: Florian Westphal <fw@strlen.de> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
This commit is contained in:
committed by
Pablo Neira Ayuso
parent
ba7d284a98
commit
4e25ceb80b
@@ -880,8 +880,8 @@ enum nft_chain_types {
|
||||
* @owner: module owner
|
||||
* @hook_mask: mask of valid hooks
|
||||
* @hooks: array of hook functions
|
||||
* @init: chain initialization function
|
||||
* @free: chain release function
|
||||
* @ops_register: base chain register function
|
||||
* @ops_unregister: base chain unregister function
|
||||
*/
|
||||
struct nft_chain_type {
|
||||
const char *name;
|
||||
@@ -890,8 +890,8 @@ struct nft_chain_type {
|
||||
struct module *owner;
|
||||
unsigned int hook_mask;
|
||||
nf_hookfn *hooks[NF_MAX_HOOKS];
|
||||
int (*init)(struct nft_ctx *ctx);
|
||||
void (*free)(struct nft_ctx *ctx);
|
||||
int (*ops_register)(struct net *net, const struct nf_hook_ops *ops);
|
||||
void (*ops_unregister)(struct net *net, const struct nf_hook_ops *ops);
|
||||
};
|
||||
|
||||
int nft_chain_validate_dependency(const struct nft_chain *chain,
|
||||
|
||||
Reference in New Issue
Block a user