Merge ra.kernel.org:/pub/scm/linux/kernel/git/netdev/net
This commit is contained in:
@@ -360,6 +360,16 @@ static int tcf_ctinfo_search(struct net *net, struct tc_action **a, u32 index)
|
||||
return tcf_idr_search(tn, a, index);
|
||||
}
|
||||
|
||||
static void tcf_ctinfo_cleanup(struct tc_action *a)
|
||||
{
|
||||
struct tcf_ctinfo *ci = to_ctinfo(a);
|
||||
struct tcf_ctinfo_params *cp;
|
||||
|
||||
cp = rcu_dereference_protected(ci->params, 1);
|
||||
if (cp)
|
||||
kfree_rcu(cp, rcu);
|
||||
}
|
||||
|
||||
static struct tc_action_ops act_ctinfo_ops = {
|
||||
.kind = "ctinfo",
|
||||
.id = TCA_ID_CTINFO,
|
||||
@@ -367,6 +377,7 @@ static struct tc_action_ops act_ctinfo_ops = {
|
||||
.act = tcf_ctinfo_act,
|
||||
.dump = tcf_ctinfo_dump,
|
||||
.init = tcf_ctinfo_init,
|
||||
.cleanup= tcf_ctinfo_cleanup,
|
||||
.walk = tcf_ctinfo_walker,
|
||||
.lookup = tcf_ctinfo_search,
|
||||
.size = sizeof(struct tcf_ctinfo),
|
||||
|
@@ -537,6 +537,9 @@ static int tcf_ife_init(struct net *net, struct nlattr *nla,
|
||||
}
|
||||
|
||||
ife = to_ife(*a);
|
||||
if (ret == ACT_P_CREATED)
|
||||
INIT_LIST_HEAD(&ife->metalist);
|
||||
|
||||
err = tcf_action_check_ctrlact(parm->action, tp, &goto_ch, extack);
|
||||
if (err < 0)
|
||||
goto release_idr;
|
||||
@@ -566,10 +569,6 @@ static int tcf_ife_init(struct net *net, struct nlattr *nla,
|
||||
p->eth_type = ife_type;
|
||||
}
|
||||
|
||||
|
||||
if (ret == ACT_P_CREATED)
|
||||
INIT_LIST_HEAD(&ife->metalist);
|
||||
|
||||
if (tb[TCA_IFE_METALST]) {
|
||||
err = nla_parse_nested_deprecated(tb2, IFE_META_MAX,
|
||||
tb[TCA_IFE_METALST], NULL,
|
||||
|
Reference in New Issue
Block a user