From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com, Dan Carpenter <error27@gmail.com>
Subject: lib/kunit/test.c:336 __kunit_abort() warn: ignoring unreachable code.
Date: Sat, 26 Aug 2023 18:29:15 +0800 [thread overview]
Message-ID: <202308261835.XGKyoddf-lkp@intel.com> (raw)
BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
CC: linux-kernel@vger.kernel.org
TO: David Gow <davidgow@google.com>
CC: Shuah Khan <skhan@linuxfoundation.org>
CC: Miguel Ojeda <ojeda@kernel.org>
CC: Daniel Latypov <dlatypov@google.com>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 7d2f353b2682dcfe5f9bc71e5b61d5b61770d98e
commit: 260755184cbdb267a046e7ffd397c1d2ba09bb5e kunit: Move kunit_abort() call out of kunit_do_failed_assertion()
date: 3 months ago
:::::: branch date: 10 hours ago
:::::: commit date: 3 months ago
config: x86_64-randconfig-161-20230823 (https://download.01.org/0day-ci/archive/20230826/202308261835.XGKyoddf-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce: (https://download.01.org/0day-ci/archive/20230826/202308261835.XGKyoddf-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Dan Carpenter <error27@gmail.com>
| Closes: https://lore.kernel.org/r/202308261835.XGKyoddf-lkp@intel.com/
smatch warnings:
lib/kunit/test.c:336 __kunit_abort() warn: ignoring unreachable code.
vim +336 lib/kunit/test.c
73cda7bb8bfb1d Brendan Higgins 2019-09-23 325
260755184cbdb2 David Gow 2023-05-31 326 void __noreturn __kunit_abort(struct kunit *test)
5f3e06208920ee Brendan Higgins 2019-09-23 327 {
5f3e06208920ee Brendan Higgins 2019-09-23 328 kunit_try_catch_throw(&test->try_catch); /* Does not return. */
5f3e06208920ee Brendan Higgins 2019-09-23 329
5f3e06208920ee Brendan Higgins 2019-09-23 330 /*
5f3e06208920ee Brendan Higgins 2019-09-23 331 * Throw could not abort from test.
5f3e06208920ee Brendan Higgins 2019-09-23 332 *
5f3e06208920ee Brendan Higgins 2019-09-23 333 * XXX: we should never reach this line! As kunit_try_catch_throw is
5f3e06208920ee Brendan Higgins 2019-09-23 334 * marked __noreturn.
5f3e06208920ee Brendan Higgins 2019-09-23 335 */
5f3e06208920ee Brendan Higgins 2019-09-23 @336 WARN_ONCE(true, "Throw could not abort from test!\n");
5f3e06208920ee Brendan Higgins 2019-09-23 337 }
260755184cbdb2 David Gow 2023-05-31 338 EXPORT_SYMBOL_GPL(__kunit_abort);
5f3e06208920ee Brendan Higgins 2019-09-23 339
:::::: The code at line 336 was first introduced by commit
:::::: 5f3e06208920ee78b68cf3527f40ffbff83cb3bc kunit: test: add support for test abort
:::::: TO: Brendan Higgins <brendanhiggins@google.com>
:::::: CC: Shuah Khan <skhan@linuxfoundation.org>
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next reply other threads:[~2023-08-26 10:29 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-26 10:29 kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2023-11-05 18:00 lib/kunit/test.c:336 __kunit_abort() warn: ignoring unreachable code kernel test robot
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=202308261835.XGKyoddf-lkp@intel.com \
--to=lkp@intel.com \
--cc=error27@gmail.com \
--cc=oe-kbuild@lists.linux.dev \
/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.