netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Davide Caratti <dcaratti@redhat.com>
To: netdev@vger.kernel.org
Subject: Re: [PATCH net 1/1] tc-testing: Update police test cases
Date: Thu, 8 Jul 2021 20:17:54 +0200	[thread overview]
Message-ID: <YOdBUjdGZQUeqX8s@dcaratti.users.ipa.redhat.com> (raw)
In-Reply-To: <f8328b65-c8db-a6ae-2e57-5d1807be4afd@mojatatu.com>

On Thu, Jul 08, 2021 at 09:05:03AM -0400, Jamal Hadi Salim wrote:
> On 2021-07-08 8:11 a.m., Roi Dayan wrote:
> 
> [..]
> > 
> > no. old output doesn't have the string "index" and also output of index
> > is in hex.
> > 
> > it is possible to make the old version work by allowing without index
> > and looking for either the unsigned number or hex number/
> > 
> > but why do we need the old output to work? could use the "old" version
> > of the test.
> 
> I think that would work if you assume this is only going to run
> on the same kernel. But:

in my perspective, that's already an issue (though a small one), because
somebody needs to ensure that a kernel is tested against a specific version
of iproute2. I say "small", because most probably the test will be waived
or skipped until all the changes (in iproute and kselftests) propagate.

> In this case because output json, which provides a formally parseable
> output, then very likely someone's scripts are dependent on the old
> output out there. So things have to be backward/forward compatible.
> The new output does look better.

the JSON output is something newly introduced  by this  commit, and I 
agree  it's good / sane to see 'index' and decimal printout in there,
like in other TC actions.

> Maybe one approach is to have multiple matchPattern in the tests?
> Davide?

sure, that's a possibility, but then:

> We will have to deal with support issues when someone says their
> script is broken.

that's probably something we need to care of. TC police is there since a
lot of time, so there might be users expecting no "index" and hex
printout in the human-readable format. If you use the old format
string with PRINT_FP, and the new one with PRINT_JSON, you should be
able to run tools/testing/selftests/net/forwarding/* and
tools/testing/selftests/tc-testing with the same iproute program,
with no "spoecial handling" for act_police.

WDYT?
-- 
davide


  reply	other threads:[~2021-07-08 18:18 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-08  8:00 [PATCH net 1/1] tc-testing: Update police test cases Roi Dayan
2021-07-08 11:17 ` Jamal Hadi Salim
2021-07-08 12:11   ` Roi Dayan
2021-07-08 13:05     ` Jamal Hadi Salim
2021-07-08 18:17       ` Davide Caratti [this message]
2021-07-12 12:29       ` Roi Dayan

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=YOdBUjdGZQUeqX8s@dcaratti.users.ipa.redhat.com \
    --to=dcaratti@redhat.com \
    --cc=netdev@vger.kernel.org \
    /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).