netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Aaron Conole <aconole@redhat.com>
To: Jakub Kicinski <kuba@kernel.org>
Cc: Matthieu Baerts <matttbe@kernel.org>,
	 davem@davemloft.net, netdev@vger.kernel.org,
	 edumazet@google.com,  pabeni@redhat.com, andrew+netdev@lunn.ch,
	 horms@kernel.org,  linux-doc@vger.kernel.org
Subject: Re: [PATCH net-next] docs: netdev: add a note on selftest posting
Date: Fri, 07 Mar 2025 08:25:48 -0500	[thread overview]
Message-ID: <f7tr0392crn.fsf@redhat.com> (raw)
In-Reply-To: <20250306112522.0a2b38b6@kernel.org> (Jakub Kicinski's message of "Thu, 6 Mar 2025 11:25:22 -0800")

Jakub Kicinski <kuba@kernel.org> writes:

> On Thu, 6 Mar 2025 19:22:49 +0100 Matthieu Baerts wrote:
>> > +Co-posting selftests
>> > +--------------------
>> > +
>> > +Selftests should be part of the same series as the code changes.
>> > +Specifically for fixes both code change and related test should go into
>> > +the same tree (the tests may lack a Fixes tag, which is expected).  
>> 
>> Regarding the Fixes tag in the tests, could we eventually suggest using
>> the same one as for the code change?
>> 
>> Sometimes, I do that to get the corresponding test backported as well,
>> if there are no conflicts. That's good to have an easy way to check if
>> something has been correctly fixed on stable versions as well.
>
> Hm, that's probably up to the stable team to decide. My intuition
> is to reserve Fixes tags for fixes, and add another tag if necessary.

+1

You could consider something like "Tests: xxx", but the problem is that
not every fix will perfectly map to a test, and as noted below, it is
possible that the fixes don't merge cleanly.  I don't know if there
would be a good tag that makes sense, really.

> The mention of the Fixes tag was primarily because of NIPA checks...
> A bit of a wink and a nod since we try not to speak about NIPA checks.
>
>> The only thing is with the selftests written in Python or Bash: it is
>> easy to get a situation where there are no conflicts, but the
>> modification doesn't work, e.g. some functions or variables are not
>> available, etc. The stable team will then not notice that during their
>> build tests. Not sure if my suggestion is safe to recommend then.

I also would note that I like the approach where the test cases detect
if the condition is even possible and [SKIP] if it isn't.  The reason is
that we can then run the latest and greatest copies of the selftest
suite against even older kernels.  Reality, it is not always possible to
do that either - so it probably needs to be case-by-case basis anyway.

> Good point..


  reply	other threads:[~2025-03-07 13:25 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-06 18:05 [PATCH net-next] docs: netdev: add a note on selftest posting Jakub Kicinski
2025-03-06 18:22 ` Matthieu Baerts
2025-03-06 19:25   ` Jakub Kicinski
2025-03-07 13:25     ` Aaron Conole [this message]
2025-03-06 23:31 ` Cong Wang
2025-03-07  0:41 ` Kuniyuki Iwashima
2025-03-07  1:15   ` Jakub Kicinski
2025-03-11 12:40 ` patchwork-bot+netdevbpf

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=f7tr0392crn.fsf@redhat.com \
    --to=aconole@redhat.com \
    --cc=andrew+netdev@lunn.ch \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=matttbe@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.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).