Lines Matching refs:exts

3035 void tcf_exts_destroy(struct tcf_exts *exts)  in tcf_exts_destroy()  argument
3038 if (exts->actions) { in tcf_exts_destroy()
3039 tcf_action_destroy(exts->actions, TCA_ACT_UNBIND); in tcf_exts_destroy()
3040 kfree(exts->actions); in tcf_exts_destroy()
3042 exts->nr_actions = 0; in tcf_exts_destroy()
3048 struct nlattr *rate_tlv, struct tcf_exts *exts, in tcf_exts_validate_ex() argument
3057 if (exts->police && tb[exts->police]) { in tcf_exts_validate_ex()
3060 a_o = tc_action_load_ops(tb[exts->police], true, in tcf_exts_validate_ex()
3066 act = tcf_action_init_1(net, tp, tb[exts->police], in tcf_exts_validate_ex()
3073 act->type = exts->type = TCA_OLD_COMPAT; in tcf_exts_validate_ex()
3074 exts->actions[0] = act; in tcf_exts_validate_ex()
3075 exts->nr_actions = 1; in tcf_exts_validate_ex()
3076 tcf_idr_insert_many(exts->actions); in tcf_exts_validate_ex()
3077 } else if (exts->action && tb[exts->action]) { in tcf_exts_validate_ex()
3081 err = tcf_action_init(net, tp, tb[exts->action], in tcf_exts_validate_ex()
3082 rate_tlv, exts->actions, init_res, in tcf_exts_validate_ex()
3087 exts->nr_actions = err; in tcf_exts_validate_ex()
3091 if ((exts->action && tb[exts->action]) || in tcf_exts_validate_ex()
3092 (exts->police && tb[exts->police])) { in tcf_exts_validate_ex()
3103 struct nlattr *rate_tlv, struct tcf_exts *exts, in tcf_exts_validate() argument
3106 return tcf_exts_validate_ex(net, tp, tb, rate_tlv, exts, in tcf_exts_validate()
3123 static struct tc_action *tcf_exts_first_act(struct tcf_exts *exts) in tcf_exts_first_act() argument
3125 if (exts->nr_actions == 0) in tcf_exts_first_act()
3128 return exts->actions[0]; in tcf_exts_first_act()
3132 int tcf_exts_dump(struct sk_buff *skb, struct tcf_exts *exts) in tcf_exts_dump() argument
3137 if (exts->action && tcf_exts_has_actions(exts)) { in tcf_exts_dump()
3143 if (exts->type != TCA_OLD_COMPAT) { in tcf_exts_dump()
3144 nest = nla_nest_start_noflag(skb, exts->action); in tcf_exts_dump()
3148 if (tcf_action_dump(skb, exts->actions, 0, 0, false) in tcf_exts_dump()
3152 } else if (exts->police) { in tcf_exts_dump()
3153 struct tc_action *act = tcf_exts_first_act(exts); in tcf_exts_dump()
3154 nest = nla_nest_start_noflag(skb, exts->police); in tcf_exts_dump()
3173 int tcf_exts_terse_dump(struct sk_buff *skb, struct tcf_exts *exts) in tcf_exts_terse_dump() argument
3178 if (!exts->action || !tcf_exts_has_actions(exts)) in tcf_exts_terse_dump()
3181 nest = nla_nest_start_noflag(skb, exts->action); in tcf_exts_terse_dump()
3185 if (tcf_action_dump(skb, exts->actions, 0, 0, true) < 0) in tcf_exts_terse_dump()
3199 int tcf_exts_dump_stats(struct sk_buff *skb, struct tcf_exts *exts) in tcf_exts_dump_stats() argument
3202 struct tc_action *a = tcf_exts_first_act(exts); in tcf_exts_dump_stats()
3574 const struct tcf_exts *exts, in tc_setup_offload_action() argument
3578 if (!exts) in tc_setup_offload_action()
3581 return tc_setup_action(flow_action, exts->actions, extack); in tc_setup_offload_action()
3588 unsigned int tcf_exts_num_actions(struct tcf_exts *exts) in tcf_exts_num_actions() argument
3594 tcf_exts_for_each_action(i, act, exts) { in tcf_exts_num_actions()