From: Davide Caratti <dcaratti@redhat.com>
To: Jamal Hadi Salim <jhs@mojatatu.com>,
Jiri Pirko <jiri@resnulli.us>,
Cong Wang <xiyou.wangcong@gmail.com>,
"David S. Miller" <davem@davemloft.net>,
netdev@vger.kernel.org
Subject: Re: [PATCH net v2] net/sched: act_gact: properly init 'goto chain'
Date: Thu, 18 Oct 2018 17:30:24 +0200 [thread overview]
Message-ID: <33333af24adf6ef97013445c51f8ce7bd3c87a82.camel@redhat.com> (raw)
In-Reply-To: <b27083a6-ad14-0f44-f85c-1ee73b8ddb8a@mojatatu.com>
hello Jamal,
On Thu, 2018-10-18 at 08:52 -0400, Jamal Hadi Salim wrote:
> Rejection is a good solution[1].
> Would be helpful to set an ext_ack to something like
> "only one goto chain is supported currently"
ok, that's material for a v3, if you / Cong / others are ok with the other
hunks.
On Thu, 2018-10-18 at 08:52 -0400, Jamal Hadi Salim wrote:
> I didnt follow why you needed to introduce tcfg_caction...
it's a trick (maybe an abuse, up to you to decide): when the user does
# tc f a dev v0 egress matchall action pass random determ goto chain 4 5
tcfg_caction contains 'pass', tcfg_paction and tcf_action both contain
'goto chain 4'. On the opposite, when the user does
# tc f a dev v0 egress matchall action goto chain 4 random determ drop 5
tcfg_caction and tcf_action both contain 'goto chain 4', and tcf_paction
contains 'drop'. In this way, the 'goto chain' is always stored in
tcf_action, so that TC generic code can always initialize a->goto_chain.
(we need tcf_caction, becaue tcf_gact_dump() and helpers in tc_gact.h need
to read the control action on the left of "random")
The alternative is, we systematically forbid usage of 'goto chain' in
tcfg_paction, so that:
# tc f a dev v0 egress matchall action <whatever> random determ goto chain 4 5
is systematically rejected with -EINVAL. This comand never worked, so we
are not breaking anything in userspace.
thanks for reviewing!
--
davide
next prev parent reply other threads:[~2018-10-18 23:31 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-18 12:05 [PATCH net v2] net/sched: act_gact: properly init 'goto chain' Davide Caratti
2018-10-18 12:52 ` Jamal Hadi Salim
2018-10-18 15:30 ` Davide Caratti [this message]
2018-10-19 20:40 ` Cong Wang
2018-10-20 21:40 ` Davide Caratti
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=33333af24adf6ef97013445c51f8ce7bd3c87a82.camel@redhat.com \
--to=dcaratti@redhat.com \
--cc=davem@davemloft.net \
--cc=jhs@mojatatu.com \
--cc=jiri@resnulli.us \
--cc=netdev@vger.kernel.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