All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: David Gow <davidgow@google.com>,
	Brendan Higgins <brendanhiggins@google.com>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Jonathan Corbet <corbet@lwn.net>,
	Andrew Morton <akpm@linux-foundation.org>,
	Kees Cook <keescook@chromium.org>,
	Shuah Khan <skhan@linuxfoundation.org>, Greg KH <greg@kroah.com>,
	Luis Chamberlain <mcgrof@kernel.org>,
	Masahiro Yamada <masahiroy@kernel.org>
Cc: kbuild-all@lists.01.org,
	Linux Memory Management List <linux-mm@kvack.org>,
	David Gow <davidgow@google.com>,
	"Guilherme G . Piccoli" <gpiccoli@igalia.com>,
	Sebastian Reichel <sre@kernel.org>,
	John Ogness <john.ogness@linutronix.de>,
	Joe Fradley <joefradley@google.com>,
	Daniel Latypov <dlatypov@google.com>,
	kunit-dev@googlegroups.com, linux-kselftest@vger.kernel.org,
	linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
	Jani Nikula <jani.nikula@linux.intel.com>,
	Lucas De Marchi <lucas.demarchi@intel.com>,
	Aaron Tomlin <atomlin@redhat.com>,
	linux-fsdevel@vger.kernel.org, linux-block@vger.kernel.org,
	Michal Marek <michal.lkml@markovi.net>,
	Nick Desaulniers <ndesaulniers@google.com>,
	linux-kbuild@vger.kernel.org
Subject: Re: [PATCH v4 4/4] selftest: Taint kernel when test module loaded
Date: Sat, 2 Jul 2022 01:37:08 +0800	[thread overview]
Message-ID: <202207020132.SKDpQP9D-lkp@intel.com> (raw)
In-Reply-To: <20220701084744.3002019-4-davidgow@google.com>

Hi David,

I love your patch! Yet something to improve:

[auto build test ERROR on masahiroy-kbuild/for-next]
[also build test ERROR on shuah-kselftest/next linus/master v5.19-rc4 next-20220701]
[cannot apply to mcgrof/modules-next]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/intel-lab-lkp/linux/commits/David-Gow/panic-Taint-kernel-if-tests-are-run/20220701-164843
base:   https://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild.git for-next
config: alpha-randconfig-r006-20220629 (https://download.01.org/0day-ci/archive/20220702/202207020132.SKDpQP9D-lkp@intel.com/config)
compiler: alpha-linux-gcc (GCC) 11.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://github.com/intel-lab-lkp/linux/commit/42b6461d6cca4baeeeed474b1400e203057c2b9b
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review David-Gow/panic-Taint-kernel-if-tests-are-run/20220701-164843
        git checkout 42b6461d6cca4baeeeed474b1400e203057c2b9b
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=alpha SHELL=/bin/bash

If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>

All errors (new ones prefixed by >>):

   In file included from lib/test_printf.c:27:
   lib/test_printf.c: In function 'test_printf_init':
>> lib/../tools/testing/selftests/kselftest_module.h:45:19: error: 'TAINT_KUNIT' undeclared (first use in this function)
      45 |         add_taint(TAINT_KUNIT, LOCKDEP_STILL_OK);       \
         |                   ^~~~~~~~~~~
   lib/test_printf.c:801:1: note: in expansion of macro 'KSTM_MODULE_LOADERS'
     801 | KSTM_MODULE_LOADERS(test_printf);
         | ^~~~~~~~~~~~~~~~~~~
   lib/../tools/testing/selftests/kselftest_module.h:45:19: note: each undeclared identifier is reported only once for each function it appears in
      45 |         add_taint(TAINT_KUNIT, LOCKDEP_STILL_OK);       \
         |                   ^~~~~~~~~~~
   lib/test_printf.c:801:1: note: in expansion of macro 'KSTM_MODULE_LOADERS'
     801 | KSTM_MODULE_LOADERS(test_printf);
         | ^~~~~~~~~~~~~~~~~~~


vim +/TAINT_KUNIT +45 lib/../tools/testing/selftests/kselftest_module.h

    40	
    41	#define KSTM_MODULE_LOADERS(__module)			\
    42	static int __init __module##_init(void)			\
    43	{							\
    44		pr_info("loaded.\n");				\
  > 45		add_taint(TAINT_KUNIT, LOCKDEP_STILL_OK);	\
    46		selftest();					\
    47		return kstm_report(total_tests, failed_tests, skipped_tests);	\
    48	}							\
    49	static void __exit __module##_exit(void)		\
    50	{							\
    51		pr_info("unloaded.\n");				\
    52	}							\
    53	module_init(__module##_init);				\
    54	module_exit(__module##_exit)
    55	

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

  parent reply	other threads:[~2022-07-01 17:38 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-01  8:47 [PATCH v4 1/4] panic: Taint kernel if tests are run David Gow
2022-07-01  8:47 ` [PATCH v4 2/4] module: panic: Taint the kernel when selftest modules load David Gow
2022-07-01  8:55   ` Greg KH
2022-07-01  9:27     ` David Gow
2022-07-01 22:30   ` Luis Chamberlain
2022-07-02  2:48     ` David Gow
2022-07-02  2:48       ` David Gow
2022-07-01  8:47 ` [PATCH v4 3/4] kunit: Taint the kernel when KUnit tests are run David Gow
2022-07-01 11:55   ` Maíra Canal
2022-07-01  8:47 ` [PATCH v4 4/4] selftest: Taint kernel when test module loaded David Gow
2022-07-01 17:16   ` kernel test robot
2022-07-01 17:37   ` kernel test robot [this message]
2022-07-01 22:33   ` Luis Chamberlain
2022-07-02  4:06     ` David Gow
2022-07-02  5:15       ` David Gow

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=202207020132.SKDpQP9D-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=akpm@linux-foundation.org \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=atomlin@redhat.com \
    --cc=brendanhiggins@google.com \
    --cc=corbet@lwn.net \
    --cc=davidgow@google.com \
    --cc=dlatypov@google.com \
    --cc=gpiccoli@igalia.com \
    --cc=greg@kroah.com \
    --cc=jani.nikula@linux.intel.com \
    --cc=joefradley@google.com \
    --cc=john.ogness@linutronix.de \
    --cc=kbuild-all@lists.01.org \
    --cc=keescook@chromium.org \
    --cc=kunit-dev@googlegroups.com \
    --cc=linux-block@vger.kernel.org \
    --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-mm@kvack.org \
    --cc=lucas.demarchi@intel.com \
    --cc=masahiroy@kernel.org \
    --cc=mcgrof@kernel.org \
    --cc=michal.lkml@markovi.net \
    --cc=ndesaulniers@google.com \
    --cc=skhan@linuxfoundation.org \
    --cc=sre@kernel.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 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.