From: Davide Caratti <dcaratti@redhat.com>
To: Cong Wang <xiyou.wangcong@gmail.com>
Cc: Jiri Pirko <jiri@resnulli.us>,
Jamal Hadi Salim <jhs@mojatatu.com>,
David Miller <davem@davemloft.net>,
Linux Kernel Network Developers <netdev@vger.kernel.org>
Subject: Re: [PATCH net] net/sched: properly init chain in case of multiple control actions
Date: Sat, 13 Oct 2018 17:23:06 +0200 [thread overview]
Message-ID: <dbb93ac2c87c14d412a18f35701890dcc87d0cdb.camel@redhat.com> (raw)
In-Reply-To: <CAM_iQpUrQTX25c2ujbHu2O0dSiTzwuc8ms-cbiUo=bUz1Xgcug@mail.gmail.com>
On Fri, 2018-10-12 at 13:57 -0700, Cong Wang wrote:
> Why not just validate the fallback action in each action init()?
> For example, checking tcfg_paction in tcf_gact_init().
>
> I don't see the need of making it generic.
hello Cong, once again thanks for looking at this.
what you say is doable, and I evaluated doing it before proposing this
patch.
But I felt unconfortable, because I needed to pass struct tcf_proto *tp in
tcf_gact_init() to initialize a->goto_chain with the chain_idx encoded in
the fallback action. So, I would have changed all the init() functions in
all TC actions, just to fix two of them.
A (legal?) trick is to let tcf_action store the fallback action when it
contains a 'goto chain' command, I just posted a proposal for gact. If you
think it's ok, I will test and post the same for act_police.
regards,
--
davide
next prev parent reply other threads:[~2018-10-13 23:00 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-12 20:39 [PATCH net] net/sched: properly init chain in case of multiple control actions Davide Caratti
2018-10-12 20:57 ` Cong Wang
2018-10-13 15:23 ` Davide Caratti [this message]
2018-10-14 13:46 ` Jamal Hadi Salim
2018-10-14 14:14 ` Davide Caratti
2018-10-15 18:31 ` Cong Wang
2018-10-16 17:38 ` Davide Caratti
2018-10-18 5:35 ` Cong Wang
2018-10-18 8:38 ` 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=dbb93ac2c87c14d412a18f35701890dcc87d0cdb.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;
as well as URLs for NNTP newsgroup(s).