From: Pablo Neira Ayuso <pablo@netfilter.org>
To: Xin Long <lucien.xin@gmail.com>
Cc: network dev <netdev@vger.kernel.org>,
dev@openvswitch.org, ovs-dev@openvswitch.org,
davem@davemloft.net, kuba@kernel.org,
Eric Dumazet <edumazet@google.com>,
Paolo Abeni <pabeni@redhat.com>,
Pravin B Shelar <pshelar@ovn.org>,
Jamal Hadi Salim <jhs@mojatatu.com>,
Cong Wang <xiyou.wangcong@gmail.com>,
Jiri Pirko <jiri@resnulli.us>, Florian Westphal <fw@strlen.de>,
Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>,
Davide Caratti <dcaratti@redhat.com>, Oz Shlomo <ozsh@nvidia.com>,
Paul Blakey <paulb@nvidia.com>,
Ilya Maximets <i.maximets@ovn.org>,
Eelco Chaudron <echaudro@redhat.com>
Subject: Re: [PATCH net-next 3/3] net: sched: add helper support in act_ct
Date: Thu, 6 Oct 2022 16:11:24 +0200 [thread overview]
Message-ID: <Yz7iDEjVbHrPUPT4@salvia> (raw)
In-Reply-To: <bc53ffac4d6be2616d053684fb6670f478b4324b.1664932669.git.lucien.xin@gmail.com>
On Tue, Oct 04, 2022 at 09:19:56PM -0400, Xin Long wrote:
[...]
> @@ -1119,6 +1135,22 @@ static int tcf_ct_act(struct sk_buff *skb, const struct tc_action *a,
> if (err != NF_ACCEPT)
> goto drop;
>
> + if (commit && p->helper && !nfct_help(ct)) {
> + err = __nf_ct_try_assign_helper(ct, p->tmpl, GFP_ATOMIC);
> + if (err)
> + goto drop;
> + add_helper = true;
> + if (p->ct_action & TCA_CT_ACT_NAT && !nfct_seqadj(ct)) {
> + if (!nfct_seqadj_ext_add(ct))
You can only add ct extensions if ct is !nf_ct_is_confirmed(ct)), is
this guaranteed in this codepath?
> + return -EINVAL;
> + }
> + }
> +
> + if (nf_ct_is_confirmed(ct) ? ((!cached && !skip_add) || add_helper) : commit) {
> + if (nf_ct_helper(skb, family) != NF_ACCEPT)
> + goto drop;
> + }
> +
> if (commit) {
> tcf_ct_act_set_mark(ct, p->mark, p->mark_mask);
> tcf_ct_act_set_labels(ct, p->labels, p->labels_mask);
next prev parent reply other threads:[~2022-10-06 14:19 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-05 1:19 [PATCH net-next 0/3] net: add helper support in tc act_ct for ovs offloading Xin Long
2022-10-05 1:19 ` [PATCH net-next 1/3] net: move the helper function to nf_conntrack_helper for ovs and tc Xin Long
2022-10-05 1:19 ` [PATCH net-next 2/3] net: sched: call tcf_ct_params_free to free params in tcf_ct_init Xin Long
2022-10-05 1:19 ` [PATCH net-next 3/3] net: sched: add helper support in act_ct Xin Long
2022-10-06 9:57 ` Paolo Abeni
2022-10-06 14:05 ` Xin Long
2022-10-06 14:11 ` Pablo Neira Ayuso [this message]
2022-10-06 16:49 ` Xin Long
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Yz7iDEjVbHrPUPT4@salvia \
--to=pablo@netfilter.org \
--cc=davem@davemloft.net \
--cc=dcaratti@redhat.com \
--cc=dev@openvswitch.org \
--cc=echaudro@redhat.com \
--cc=edumazet@google.com \
--cc=fw@strlen.de \
--cc=i.maximets@ovn.org \
--cc=jhs@mojatatu.com \
--cc=jiri@resnulli.us \
--cc=kuba@kernel.org \
--cc=lucien.xin@gmail.com \
--cc=marcelo.leitner@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=ovs-dev@openvswitch.org \
--cc=ozsh@nvidia.com \
--cc=pabeni@redhat.com \
--cc=paulb@nvidia.com \
--cc=pshelar@ovn.org \
--cc=xiyou.wangcong@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox