linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jean Delvare <jdelvare@suse.de>
To: Mark Brown <broonie@kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>
Subject: Re: [PATCH] ASoC: rsnd: Drop obsolete dependency on COMPILE_TEST
Date: Mon, 28 Nov 2022 14:56:12 +0100	[thread overview]
Message-ID: <20221128145612.74ff3d25@endymion.delvare> (raw)
In-Reply-To: <Y4Sqn0xOP4R/fl9P@sirena.org.uk>

Hi Mark,

On Mon, 28 Nov 2022 12:33:35 +0000, Mark Brown wrote:
> On Sun, Nov 27, 2022 at 07:34:41PM +0100, Jean Delvare wrote:
> > It is actually better to always build such drivers with OF enabled,
> > so that the test builds are closer to how each driver will actually be
> > built on its intended target. Building them without OF may not test
> > much as the compiler will optimize out potentially large parts of the
> > code. In the worst case, this could even pop false positive warnings.
> > Dropping COMPILE_TEST here improves the quality of our testing and
> > avoids wasting time on non-existent issues.  
> 
> As ever building without OF does not preclude building with OF.

I'm sorry, I'm not sure I understand what point you are trying to make
here.

Of course you can build a kernel with and without OF, and without my
patch, you could build the driver with and without OF. My point is that
there is no value in allowing that.

There are 2 use cases for COMPILE_TEST. The first use case is kernel
developers who make changes to a driver and want to be able to
test-build it. Now they can just enable OF and they will be able to
test-build the driver (and a better version of it, as explained in my
patch description). It is no different from enabling I2C if you need to
test-build an I2C driver, or enabling SPI if you need to test-build an
SPI driver, etc.

The second use case is the compilation farms. These will typically run
pre-defined real kernel configurations or allmodconfig or randconfig.
The first two options are not really affected by this change, only
randconfig is.

For randconfig, the limiting factor is the build power of the farm. So,
in a way, yes building without OF does preclude building with OF,
because you can test only one combination of options at once. Whenever
you build your driver without OF, you are wasting an opportunity to
build it with OF instead, which would test the code as it will actually
be used on its intended target, and thus is a better test.

You may argue that statistically, randconfig will select the driver
more often if it depends on OF || COMPILE_TEST rather than just OF.
That's true, but it's a matter of quantity versus quality. Would you
rather test build the code twice in its crippled form, which may
trigger false-positive warnings or hide actual warnings, or just once
in its proper form, where all warnings and build failures are real? I
definitely believe the latter is a better use of our resources.

Thanks,
-- 
Jean Delvare
SUSE L3 Support

  reply	other threads:[~2022-11-28 13:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-27 18:34 [PATCH] ASoC: rsnd: Drop obsolete dependency on COMPILE_TEST Jean Delvare
2022-11-28 12:33 ` Mark Brown
2022-11-28 13:56   ` Jean Delvare [this message]
2022-11-28 17:56     ` Mark Brown
2022-11-28 16:39 ` Mark Brown

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=20221128145612.74ff3d25@endymion.delvare \
    --to=jdelvare@suse.de \
    --cc=broonie@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=perex@perex.cz \
    --cc=tiwai@suse.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).