netfilter: Remove useless param helper of nf_ct_helper_ext_add
The param helper of nf_ct_helper_ext_add is useless now, then remove it now. Signed-off-by: Gao Feng <gfree.wind@vip.163.com> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
This commit is contained in:
parent
762c400766
commit
440534d3c5
|
@ -103,9 +103,7 @@ int nf_conntrack_helpers_register(struct nf_conntrack_helper *, unsigned int);
|
|||
void nf_conntrack_helpers_unregister(struct nf_conntrack_helper *,
|
||||
unsigned int);
|
||||
|
||||
struct nf_conn_help *nf_ct_helper_ext_add(struct nf_conn *ct,
|
||||
struct nf_conntrack_helper *helper,
|
||||
gfp_t gfp);
|
||||
struct nf_conn_help *nf_ct_helper_ext_add(struct nf_conn *ct, gfp_t gfp);
|
||||
|
||||
int __nf_ct_try_assign_helper(struct nf_conn *ct, struct nf_conn *tmpl,
|
||||
gfp_t flags);
|
||||
|
|
|
@ -1401,8 +1401,7 @@ init_conntrack(struct net *net, struct nf_conn *tmpl,
|
|||
/* exp->master safe, refcnt bumped in nf_ct_find_expectation */
|
||||
ct->master = exp->master;
|
||||
if (exp->helper) {
|
||||
help = nf_ct_helper_ext_add(ct, exp->helper,
|
||||
GFP_ATOMIC);
|
||||
help = nf_ct_helper_ext_add(ct, GFP_ATOMIC);
|
||||
if (help)
|
||||
rcu_assign_pointer(help->helper, exp->helper);
|
||||
}
|
||||
|
|
|
@ -192,8 +192,7 @@ void nf_conntrack_helper_put(struct nf_conntrack_helper *helper)
|
|||
EXPORT_SYMBOL_GPL(nf_conntrack_helper_put);
|
||||
|
||||
struct nf_conn_help *
|
||||
nf_ct_helper_ext_add(struct nf_conn *ct,
|
||||
struct nf_conntrack_helper *helper, gfp_t gfp)
|
||||
nf_ct_helper_ext_add(struct nf_conn *ct, gfp_t gfp)
|
||||
{
|
||||
struct nf_conn_help *help;
|
||||
|
||||
|
@ -262,7 +261,7 @@ int __nf_ct_try_assign_helper(struct nf_conn *ct, struct nf_conn *tmpl,
|
|||
}
|
||||
|
||||
if (help == NULL) {
|
||||
help = nf_ct_helper_ext_add(ct, helper, flags);
|
||||
help = nf_ct_helper_ext_add(ct, flags);
|
||||
if (help == NULL)
|
||||
return -ENOMEM;
|
||||
} else {
|
||||
|
|
|
@ -1947,7 +1947,7 @@ ctnetlink_create_conntrack(struct net *net,
|
|||
} else {
|
||||
struct nf_conn_help *help;
|
||||
|
||||
help = nf_ct_helper_ext_add(ct, helper, GFP_ATOMIC);
|
||||
help = nf_ct_helper_ext_add(ct, GFP_ATOMIC);
|
||||
if (help == NULL) {
|
||||
err = -ENOMEM;
|
||||
goto err2;
|
||||
|
|
|
@ -870,7 +870,7 @@ static void nft_ct_helper_obj_eval(struct nft_object *obj,
|
|||
if (test_bit(IPS_HELPER_BIT, &ct->status))
|
||||
return;
|
||||
|
||||
help = nf_ct_helper_ext_add(ct, to_assign, GFP_ATOMIC);
|
||||
help = nf_ct_helper_ext_add(ct, GFP_ATOMIC);
|
||||
if (help) {
|
||||
rcu_assign_pointer(help->helper, to_assign);
|
||||
set_bit(IPS_HELPER_BIT, &ct->status);
|
||||
|
|
|
@ -93,7 +93,7 @@ xt_ct_set_helper(struct nf_conn *ct, const char *helper_name,
|
|||
return -ENOENT;
|
||||
}
|
||||
|
||||
help = nf_ct_helper_ext_add(ct, helper, GFP_KERNEL);
|
||||
help = nf_ct_helper_ext_add(ct, GFP_KERNEL);
|
||||
if (help == NULL) {
|
||||
nf_conntrack_helper_put(helper);
|
||||
return -ENOMEM;
|
||||
|
|
|
@ -1303,7 +1303,7 @@ static int ovs_ct_add_helper(struct ovs_conntrack_info *info, const char *name,
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
help = nf_ct_helper_ext_add(info->ct, helper, GFP_KERNEL);
|
||||
help = nf_ct_helper_ext_add(info->ct, GFP_KERNEL);
|
||||
if (!help) {
|
||||
nf_conntrack_helper_put(helper);
|
||||
return -ENOMEM;
|
||||
|
|
Loading…
Reference in New Issue