From: Karl Mehltretter <kmehltretter@gmail.com>
To: Brendan Higgins <brendan.higgins@linux.dev>,
David Gow <david@davidgow.net>, Rae Moar <raemoar63@gmail.com>
Cc: "Thomas Weißschuh" <thomas.weissschuh@linutronix.de>,
"Shuah Khan" <skhan@linuxfoundation.org>,
linux-kselftest@vger.kernel.org, kunit-dev@googlegroups.com,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH next] kunit: Initialize filter error before disabled cleanup
Date: Fri, 16 Oct 2026 06:45:02 +0200 [thread overview]
Message-ID: <atGqVhQyKowLGOz5@gmail.com> (raw)
In-Reply-To: <20260914025933.9832-1-kmehltretter@gmail.com>
On Mon, Sep 14, 2026 at 04:59:33AM +0100, Karl Mehltretter wrote:
> kunit_run_all_tests() jumps to free_out when KUnit execution is disabled.
> If a boot filter is configured, free_out tests err even though
> kunit_filter_suites() was never called to initialize it.
>
> Clang's -Wconditional-uninitialized diagnoses this path. KMSAN confirms
> the runtime use.
>
> With CONFIG_KUNIT_DEFAULT_ENABLED=n,
> CONFIG_KUNIT_DEFAULT_FILTER_GLOB="*", CONFIG_INIT_STACK_NONE=y and
> CONFIG_KMSAN=y, KMSAN reports an uninitialized-value use in
> kunit_run_all_tests() and identifies local variable err as its origin.
>
> Restore the zero initializer. It remains necessary as cleanup state after
> kunit_run_all_tests() was changed to return void.
>
> Fixes: e38f53f04824 ("kunit: Return void from kunit_run_all_tests()")
> Signed-off-by: Karl Mehltretter <kmehltretter@gmail.com>
Friendly ping on this fix. It has Thomas's Reviewed-by tag.
I don't see this fix in the KUnit tree or folded into the original
change.
Thanks,
Karl
prev parent reply other threads:[~2026-10-16 4:45 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-01 9:50 [PATCH] kunit: Return void from kunit_run_all_tests() Thomas Weißschuh
2026-09-02 13:29 ` David Gow
2026-09-14 2:59 ` [PATCH next] kunit: Initialize filter error before disabled cleanup Karl Mehltretter
2026-09-25 7:43 ` Thomas Weißschuh
2026-10-16 4:45 ` Karl Mehltretter [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=atGqVhQyKowLGOz5@gmail.com \
--to=kmehltretter@gmail.com \
--cc=brendan.higgins@linux.dev \
--cc=david@davidgow.net \
--cc=kunit-dev@googlegroups.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=raemoar63@gmail.com \
--cc=skhan@linuxfoundation.org \
--cc=thomas.weissschuh@linutronix.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.