linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Brendan Higgins <brendanhiggins@google.com>
To: shuah <shuah@kernel.org>
Cc: "Theodore Ts'o" <tytso@mit.edu>,
	Frank Rowand <frowand.list@gmail.com>,
	Greg KH <gregkh@linuxfoundation.org>,
	Josh Poimboeuf <jpoimboe@redhat.com>,
	Kees Cook <keescook@google.com>,
	Kieran Bingham <kieran.bingham@ideasonboard.com>,
	Luis Chamberlain <mcgrof@kernel.org>,
	Peter Zijlstra <peterz@infradead.org>,
	Rob Herring <robh@kernel.org>, Stephen Boyd <sboyd@kernel.org>,
	Masahiro Yamada <yamada.masahiro@socionext.com>,
	devicetree <devicetree@vger.kernel.org>,
	dri-devel <dri-devel@lists.freedesktop.org>,
	kunit-dev@googlegroups.com,
	"open list:DOCUMENTATION" <linux-doc@vger.kernel.org>,
	linux-fsdevel@vger.kernel.org,
	linux-kbuild <linux-kbuild@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	"open list:KERNEL SELFTEST FRAMEWORK" 
	<linux-kselftest@vger.kernel.org>,
	linux-nvdimm <linux-nvdimm@lists.01.org>,
	linux-um@lists.infradead.org,
	Sasha Levin <Alexander.Levin@microsoft.com>,
	"Bird, Timothy" <Tim.Bird@sony.com>,
	Amir Goldstein <amir73il@gmail.com>,
	Dan Carpenter <dan.carpenter@oracle.com>,
	Daniel Vetter <daniel@ffwll.ch>, Jeff Dike <jdike@addtoit.com>,
	Joel Stanley <joel@jms.id.au>,
	Julia Lawall <julia.lawall@lip6.fr>,
	Kevin Hilman <khilman@baylibre.com>,
	Knut Omang <knut.omang@oracle.com>,
	Logan Gunthorpe <logang@deltatee.com>,
	Michael Ellerman <mpe@ellerman.id.au>,
	Petr Mladek <pmladek@suse.com>,
	Randy Dunlap <rdunlap@infradead.org>,
	Richard Weinberger <richard@nod.at>,
	David Rientjes <rientjes@google.com>,
	Steven Rostedt <rostedt@goodmis.org>,
	wfg@linux.intel.com
Subject: Re: [PATCH v5 00/18] kunit: introduce KUnit, the Linux kernel unit testing framework
Date: Wed, 3 Jul 2019 16:40:50 -0700	[thread overview]
Message-ID: <CAFd5g4515jAOzEtiZfXP0d6YUgOxOZCknw0Nd-2wsY=mPFdGqg@mail.gmail.com> (raw)
In-Reply-To: <CAFd5g46W1u+6JKLW0WX9uicK5utvJe9tvq4YBsCkghuo0rCmng@mail.gmail.com>

On Fri, Jun 21, 2019 at 5:54 PM Brendan Higgins
<brendanhiggins@google.com> wrote:
>
> On Fri, Jun 21, 2019 at 12:21 PM shuah <shuah@kernel.org> wrote:
> >
> > On 6/21/19 12:13 PM, Theodore Ts'o wrote:
> > > On Fri, Jun 21, 2019 at 08:59:48AM -0600, shuah wrote:
> > >>>> ### But wait! Doesn't kselftest support in kernel testing?!
> > >>>>
> > >>>> ....
> > >>
> > >> I think I commented on this before. I agree with the statement that
> > >> there is no overlap between Kselftest and KUnit. I would like see this
> > >> removed. Kselftest module support supports use-cases KUnit won't be able
> > >> to. I can build an kernel with Kselftest test modules and use it in the
> > >> filed to load and run tests if I need to debug a problem and get data
> > >> from a system. I can't do that with KUnit.
>
> Sure, I think this point has been brought up a number of times before.
> Maybe I didn't write this section well because, like Frank said, it
> comes across as being critical of the Kselftest module support; that
> wasn't my intention. I was speaking from the perspective that
> Kselftest module support is just a feature of Kselftest, and not a
> full framework like KUnit is (obviously Kselftest itself *is* a
> framework, but a very small part of it is not).
>
> It was obvious to me what Kselftest module support was intended for,
> and it is not intended to cover the use case that KUnit is targeting.
>
> > >> In my mind, I am not viewing this as which is better. Kselftest and
> > >> KUnit both have their place in the kernel development process. It isn't
> > >> productive and/or necessary to comparing Kselftest and KUnit without a
> > >> good understanding of the problem spaces for each of these.
>
> Again, I didn't mean to draw a comparison of which is better than the
> other. I was just trying to point out that Kselftest module support
> doesn't make sense as a stand alone unit testing framework, or really
> a framework of any kind, despite how it might actually be used.
>
> > >> I would strongly recommend not making reference to Kselftest and talk
> > >> about what KUnit offers.
>
> I can see your point. It seems that both you and Frank seem to think
> that I drew a comparison between Kselftest and KUnit, which was
> unintended. I probably should have spent more time editing this
> section, but I can see the point of drawing the comparison itself
> might invite this confusion.
>
> > > Shuah,
> > >
> > > Just to recall the history, this section of the FAQ was added to rebut
> > > the ***very*** strong statements that Frank made that there was
> > > overlap between Kselftest and Kunit, and that having too many ways for
> > > kernel developers to do the identical thing was harmful (he said it
> > > was too much of a burden on a kernel developer) --- and this was an
> > > argument for not including Kunit in the upstream kernel.
>
> I don't think he was actually advocating that we don't include KUnit,
> maybe playing devil's advocate; nevertheless, at the end, Frank seemed
> to agree that there were valuable things that KUnit offered. I thought
> he just wanted to make the point that I hadn't made the distinction
> sufficiently clear in the cover letter, and other reviewers might get
> confused in the future as well.
>
> Additionally, it does look like people were trying to use Kselftest
> module support to cover some things which really were trying to be
> unit tests. I know this isn't really intended - everything looks like
> a nail when you only have a hammer, which I think Frank was pointing
> out furthers the above confusion.
>
> In anycase, it sounds like I have, if anything, only made the
> discussion even more confusing by adding this section; sorry about
> that.
>
> > > If we're past that objection, then perhaps this section can be
> > > dropped, but there's a very good reason why it was there.  I wouldn't
> > > Brendan to be accused of ignoring feedback from those who reviewed his
> > > patches.   :-)
> > >
> >
> > Agreed. I understand that this FAQ probably was needed at one time and
> > Brendan added it to address the concerns.
>
> I don't want to speak for Frank, but I don't think it was an objection
> to KUnit itself, but rather an objection to not sufficiently
> addressing the point about how they differ.
>
> > I think at some point we do need to have a document that outlines when
> > to KUnit and when to use Kselftest modules. I think one concern people
> > have is that if KUnit is perceived as a  replacement for Ksefltest
> > module, Kselftest module will be ignored leaving users without the
> > ability to build and run with Kselftest modules and load them on a need
> > basis to gather data on a systems that aren't dedicated strictly for
> > testing.
>
> I absolutely agree! I posed a suggestion here[1], which after I just
> now searched for a link, I realize for some reason it didn't seem like
> it reached a number of the mailing lists that I sent it to, so I
> should probably resend it.
>
> Anyway, a summary of what I suggested: We should start off by better
> organizing Documentation/dev-tools/ and create a landing page that
> groups the dev-tools by function according to what person is likely to
> use them and for what. Eventually and specifically for Kselftest and
> KUnit, I would like to have a testing guide for the kernel that
> explains what testing procedure should look like and what to use and
> when.
>
> > I am trying to move the conversation forward from KUnit vs. Kselftest
> > modules discussion to which problem areas each one addresses keeping
> > in mind that it is not about which is better. Kselftest and KUnit both
> > have their place in the kernel development process. We just have to be
> > clear on usage as we write tests for each.
>
> I think that is the right long term approach. I think a good place to
> start, like I suggested above, is cleaning up
> Documentation/dev-tools/, but I think that belongs in a (probably
> several) follow-up patchset.
>
> Frank, I believe your objection was mostly related to how KUnit is
> presented specifically in the cover letter, and doesn't necessarily
> deal with the intended use case. So I don't think that doing this,
> especially doing this later, really addresses your concern. I don't
> want to belabor the issue, but I would also rather not put words in
> your mouth, what are your thoughts on the above?
>
> I think my main concern moving forward on this point is that I am not
> sure that I can address the debate that this section covers in a way
> that is both sufficiently concise for a cover letter, but also doesn't
> invite more potential confusion. My inclination at this point is to
> drop it since I think the set of reviewers for this patchset has at
> this point become fixed, and it seems that it will likely cause more
> confusion rather than reduce it; also, I don't really think this will

Since no one has objected to dropping the "### But wait! Doesn't
kselftest support in kernel testing?!" section in the past almost two
weeks, I am just going to continue on without it.

Cheers

> be an issue for end users, especially once we have proper
> documentation in place. Alternatively, I guess I could maybe address
> the point elsewhere and refer to it in the cover letter? Or maybe just
> put it at the end of the cover letter?
>
> [1] https://www.mail-archive.com/kgdb-bugreport@lists.sourceforge.net/msg05059.html

  reply	other threads:[~2019-07-03 23:41 UTC|newest]

Thread overview: 60+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-06-17  8:25 [PATCH v5 00/18] kunit: introduce KUnit, the Linux kernel unit testing framework Brendan Higgins
2019-06-17  8:25 ` [PATCH v5 01/18] kunit: test: add KUnit test runner core Brendan Higgins
2019-06-20  0:15   ` Stephen Boyd
2019-06-25 20:28     ` Brendan Higgins
2019-06-25 21:44       ` Luis Chamberlain
2019-06-25 22:14         ` Brendan Higgins
2019-06-25 23:02           ` Luis Chamberlain
2019-06-26  6:41             ` Brendan Higgins
2019-06-26 22:02               ` Luis Chamberlain
2019-06-27  0:05                 ` Brendan Higgins
2019-06-26  3:40       ` Stephen Boyd
2019-06-26 23:00         ` Brendan Higgins
2019-06-27 18:16           ` Stephen Boyd
2019-06-28  8:09             ` Brendan Higgins
2019-06-25 22:33   ` Luis Chamberlain
2019-06-26  0:07     ` Brendan Higgins
2019-06-26  3:36       ` Luis Chamberlain
2019-06-26 22:16         ` Brendan Higgins
2019-06-17  8:25 ` [PATCH v5 02/18] kunit: test: add test resource management API Brendan Higgins
2019-06-17  8:25 ` [PATCH v5 03/18] kunit: test: add string_stream a std::stream like string builder Brendan Higgins
2019-06-17  8:25 ` [PATCH v5 04/18] kunit: test: add kunit_stream a std::stream like logger Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 05/18] kunit: test: add the concept of expectations Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 06/18] kbuild: enable building KUnit Brendan Higgins
2019-06-25 22:13   ` Luis Chamberlain
2019-06-25 22:41     ` Brendan Higgins
2019-06-25 23:03       ` Luis Chamberlain
2019-06-17  8:26 ` [PATCH v5 07/18] kunit: test: add initial tests Brendan Higgins
2019-06-25 23:22   ` Luis Chamberlain
2019-06-26  7:53     ` Brendan Higgins
2019-07-02 17:52       ` Brendan Higgins
2019-07-02 20:57         ` Luis Chamberlain
2019-06-17  8:26 ` [PATCH v5 08/18] objtool: add kunit_try_catch_throw to the noreturn list Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 09/18] kunit: test: add support for test abort Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 10/18] kunit: test: add tests for kunit " Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 11/18] kunit: test: add the concept of assertions Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 12/18] kunit: test: add tests for KUnit managed resources Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 13/18] kunit: tool: add Python wrappers for running KUnit tests Brendan Higgins
2019-06-26  0:01   ` Luis Chamberlain
2019-06-26  8:02     ` Brendan Higgins
2019-06-26 22:03       ` Luis Chamberlain
2019-06-27  0:23         ` Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 14/18] kunit: defconfig: add defconfigs for building " Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 15/18] Documentation: kunit: add documentation for KUnit Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 16/18] MAINTAINERS: add entry for KUnit the unit testing framework Brendan Higgins
2019-06-17  8:26 ` [PATCH v5 17/18] kernel/sysctl-test: Add null pointer test for sysctl.c:proc_dointvec() Brendan Higgins
2019-06-26  2:17   ` Luis Chamberlain
2019-06-27  4:07     ` Iurii Zaikin
2019-06-27  6:10       ` Luis Chamberlain
2019-06-28  8:01         ` Brendan Higgins
2019-06-28 21:37           ` Luis Chamberlain
2019-06-17  8:26 ` [PATCH v5 18/18] MAINTAINERS: add proc sysctl KUnit test to PROC SYSCTL section Brendan Higgins
2019-06-26  2:19   ` Luis Chamberlain
2019-06-20  1:17 ` [PATCH v5 00/18] kunit: introduce KUnit, the Linux kernel unit testing framework Frank Rowand
2019-06-21 14:59   ` shuah
2019-06-21 18:13     ` Theodore Ts'o
2019-06-21 19:20       ` shuah
2019-06-22  0:54         ` Brendan Higgins
2019-07-03 23:40           ` Brendan Higgins [this message]
2019-06-21 23:35   ` Brendan Higgins
2019-06-26  2:38   ` Luis Chamberlain

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='CAFd5g4515jAOzEtiZfXP0d6YUgOxOZCknw0Nd-2wsY=mPFdGqg@mail.gmail.com' \
    --to=brendanhiggins@google.com \
    --cc=Alexander.Levin@microsoft.com \
    --cc=Tim.Bird@sony.com \
    --cc=amir73il@gmail.com \
    --cc=dan.carpenter@oracle.com \
    --cc=daniel@ffwll.ch \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=frowand.list@gmail.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jdike@addtoit.com \
    --cc=joel@jms.id.au \
    --cc=jpoimboe@redhat.com \
    --cc=julia.lawall@lip6.fr \
    --cc=keescook@google.com \
    --cc=khilman@baylibre.com \
    --cc=kieran.bingham@ideasonboard.com \
    --cc=knut.omang@oracle.com \
    --cc=kunit-dev@googlegroups.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=linux-nvdimm@lists.01.org \
    --cc=linux-um@lists.infradead.org \
    --cc=logang@deltatee.com \
    --cc=mcgrof@kernel.org \
    --cc=mpe@ellerman.id.au \
    --cc=peterz@infradead.org \
    --cc=pmladek@suse.com \
    --cc=rdunlap@infradead.org \
    --cc=richard@nod.at \
    --cc=rientjes@google.com \
    --cc=robh@kernel.org \
    --cc=rostedt@goodmis.org \
    --cc=sboyd@kernel.org \
    --cc=shuah@kernel.org \
    --cc=tytso@mit.edu \
    --cc=wfg@linux.intel.com \
    --cc=yamada.masahiro@socionext.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).