From: Marcelo Ricardo Leitner <marcelo.leitner@gmail•com>
To: Paolo Abeni <pabeni@redhat•com>
Cc: netdev@vger•kernel.org, Jamal Hadi Salim <jhs@mojatatu•com>,
Cong Wang <xiyou.wangcong@gmail•com>,
Jiri Pirko <jiri@resnulli•us>,
Daniel Borkmann <daniel@iogearbox•net>,
Eyal Birger <eyal.birger@gmail•com>,
"David S. Miller" <davem@davemloft•net>
Subject: Re: [PATCH net-next v4 1/4] net/sched: user-space can't set unknown tcfa_action values
Date: Thu, 26 Jul 2018 21:28:59 -0300 [thread overview]
Message-ID: <20180727002857.GC20482@localhost.localdomain> (raw)
In-Reply-To: <2717eb1db9f7b89905809d00391bdab2ad123c00.1532611319.git.pabeni@redhat.com>
Hi,
On Thu, Jul 26, 2018 at 04:34:57PM +0200, Paolo Abeni wrote:
...
> @@ -895,6 +904,14 @@ struct tc_action *tcf_action_init_1(struct net *net, struct tcf_proto *tp,
> }
> }
>
> + if (!tcf_action_valid(a->tcfa_action)) {
> + net_warn_ratelimited("invalid %d action value, using "
> + "TC_ACT_UNSPEC instead", a->tcfa_action);
Now that it is reporting the error via extack, do we really need this
warn net_warn?
extack will be shown as a warning by iproute2 even if the command
succeeds.
> + NL_SET_ERR_MSG(extack, "invalid action value, using "
> + "TC_ACT_UNSPEC instead");
Quoted strings shouldn't be broken down into multiple lines..
> + a->tcfa_action = TC_ACT_UNSPEC;
> + }
> +
> return a;
>
> err_mod:
> --
> 2.17.1
>
next prev parent reply other threads:[~2018-07-27 1:48 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-26 14:34 [PATCH net-next v4 0/4] TC: refactor act_mirred packets re-injection Paolo Abeni
2018-07-26 14:34 ` [PATCH net-next v4 1/4] net/sched: user-space can't set unknown tcfa_action values Paolo Abeni
2018-07-27 0:28 ` Marcelo Ricardo Leitner [this message]
2018-07-27 13:08 ` Paolo Abeni
2018-07-26 14:34 ` [PATCH net-next v4 2/4] tc/act: remove unneeded RCU lock in action callback Paolo Abeni
2018-07-26 14:34 ` [PATCH net-next v4 3/4] net/tc: introduce TC_ACT_REINSERT Paolo Abeni
2018-07-26 23:29 ` Cong Wang
2018-07-29 3:21 ` kbuild test robot
2018-07-29 3:34 ` kbuild test robot
2018-07-26 14:35 ` [PATCH net-next v4 4/4] act_mirred: use TC_ACT_REINSERT when possible Paolo Abeni
2018-07-26 23:27 ` Cong Wang
2018-07-29 2:58 ` kbuild test robot
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=20180727002857.GC20482@localhost.localdomain \
--to=marcelo.leitner@gmail$(echo .)com \
--cc=daniel@iogearbox$(echo .)net \
--cc=davem@davemloft$(echo .)net \
--cc=eyal.birger@gmail$(echo .)com \
--cc=jhs@mojatatu$(echo .)com \
--cc=jiri@resnulli$(echo .)us \
--cc=netdev@vger$(echo .)kernel.org \
--cc=pabeni@redhat$(echo .)com \
--cc=xiyou.wangcong@gmail$(echo .)com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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