linux-kselftest.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ulf Hansson <ulf.hansson@linaro.org>
To: David Gow <davidgow@google.com>, Daniel Latypov <dlatypov@google.com>
Cc: "Brendan Higgins" <brendanhiggins@google.com>,
	"Luis Chamberlain" <mcgrof@kernel.org>,
	"Jeremy Kerr" <jk@codeconstruct.com.au>,
	"Shuah Khan" <skhan@linuxfoundation.org>,
	"Andrew Jeffery" <andrew@aj.id.au>,
	"Mika Westerberg" <mika.westerberg@linux.intel.com>,
	"Andra Paraschiv" <andraprs@amazon.com>,
	Longpeng <longpeng2@huawei.com>,
	Paraschiv@google.com,
	"Christophe Leroy" <christophe.leroy@csgroup.eu>,
	kunit-dev@googlegroups.com, linux-kselftest@vger.kernel.org,
	linux-kernel@vger.kernel.org, "Maíra Canal" <maira.canal@usp.br>,
	linux-mmc@vger.kernel.org, linux-aspeed@lists.ozlabs.org,
	openbmc@lists.ozlabs.org, linux-usb@vger.kernel.org,
	linux-modules@vger.kernel.org,
	"Matt Johnston" <matt@codeconstruct.com.au>
Subject: Re: [PATCH v2 5/5] mmc: sdhci-of-aspeed: test: Use kunit_test_suite() macro
Date: Thu, 23 Jun 2022 14:23:57 +0200	[thread overview]
Message-ID: <CAPDyKFq0cTX5pfTLxTa9SEUBiiEcMuiEeDi3OPfMjFuBWca_jw@mail.gmail.com> (raw)
In-Reply-To: <CAGS_qxp6ZK9K0Sy1JcuU-SGqChOyr6-+5HDxgesOpxjxvDkiXQ@mail.gmail.com>

On Wed, 22 Jun 2022 at 00:19, Daniel Latypov <dlatypov@google.com> wrote:
>
>  On Tue, Jun 21, 2022 at 1:54 AM David Gow <davidgow@google.com> wrote:
> >
> > The kunit_test_suite() macro is no-longer incompatible with module_add,
> > so its use can be reinstated.
> >
> > Since this fixes parsing with builtins and kunit_tool, also enable the
> > test by default when KUNIT_ALL_TESTS is enabled.
> >
> > The test can now be run via kunit_tool with:
> >         ./tools/testing/kunit/kunit.py run --arch=x86_64 \
> >         --kconfig_add CONFIG_OF=y --kconfig_add CONFIG_OF_ADDRESS=y \
> >         --kconfig_add CONFIG_MMC=y --kconfig_add CONFIG_MMC_SDHCI=y \
> >         --kconfig_add CONFIG_MMC_SDHCI_PLTFM=y \
> >         --kconfig_add CONFIG_MMC_SDHCI_OF_ASPEED=y \
> >         'sdhci-of-aspeed'
> >
> > (It may be worth adding a .kunitconfig at some point, as there are
> > enough dependencies to make that command scarily long.)
> >
> > Signed-off-by: David Gow <davidgow@google.com>
>
> Acked-by: Daniel Latypov <dlatypov@google.com>
>
> Minor, optional suggestion below.
>
> >  static int __init aspeed_sdc_init(void)
> > @@ -639,12 +620,6 @@ static int __init aspeed_sdc_init(void)
> >         if (rc < 0)
> >                 goto cleanup_sdhci;
> >
> > -       rc = aspeed_sdc_tests_init();
> > -       if (rc < 0) {
> > -               platform_driver_unregister(&aspeed_sdc_driver);
> > -               goto cleanup_sdhci;
> > -       }
> > -
> >         return 0;
> >
> >  cleanup_sdhci:
>
> This goto was added in 4af307f57426 ("mmc: sdhci-of-aspeed: Fix
> kunit-related build error") to allow for this extra call to
> aspeed_sdc_tests_init().
>
> This could now be reverted back to what is
>         rc = platform_driver_register(&aspeed_sdc_driver);
>         if (rc < 0)
>                platform_driver_unregister(&aspeed_sdhci_driver);
>
>         return rc;
>
> but let's see what the maintainers think.

I don't have a strong opinion on this, feel free to pick any of the options.

Acked-by: Ulf Hansson <ulf.hansson@linaro.org>

Kind regards
Uffe

      reply	other threads:[~2022-06-23 12:24 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-21  8:53 [PATCH v2 0/5] Rework KUnit test execution in modules David Gow
2022-06-21  8:53 ` [PATCH v2 1/5] kunit: unify module and builtin suite definitions David Gow
2022-06-21  8:53 ` [PATCH v2 2/5] kunit: flatten kunit_suite*** to kunit_suite** in .kunit_test_suites David Gow
2022-06-21 20:29   ` Daniel Latypov
2022-06-21  8:53 ` [PATCH v2 3/5] thunderbolt: test: Use kunit_test_suite() macro David Gow
2022-06-21 20:23   ` Daniel Latypov
2022-06-22  7:16   ` David Gow
2022-06-21  8:53 ` [PATCH v2 4/5] nitro_enclaves: " David Gow
2022-06-21 15:57   ` Paraschiv, Andra-Irina
2022-06-21  8:53 ` [PATCH v2 5/5] mmc: sdhci-of-aspeed: " David Gow
2022-06-21 22:19   ` Daniel Latypov
2022-06-23 12:23     ` Ulf Hansson [this message]

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=CAPDyKFq0cTX5pfTLxTa9SEUBiiEcMuiEeDi3OPfMjFuBWca_jw@mail.gmail.com \
    --to=ulf.hansson@linaro.org \
    --cc=Paraschiv@google.com \
    --cc=andraprs@amazon.com \
    --cc=andrew@aj.id.au \
    --cc=brendanhiggins@google.com \
    --cc=christophe.leroy@csgroup.eu \
    --cc=davidgow@google.com \
    --cc=dlatypov@google.com \
    --cc=jk@codeconstruct.com.au \
    --cc=kunit-dev@googlegroups.com \
    --cc=linux-aspeed@lists.ozlabs.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-modules@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=longpeng2@huawei.com \
    --cc=maira.canal@usp.br \
    --cc=matt@codeconstruct.com.au \
    --cc=mcgrof@kernel.org \
    --cc=mika.westerberg@linux.intel.com \
    --cc=openbmc@lists.ozlabs.org \
    --cc=skhan@linuxfoundation.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).