All of lore.kernel.org
 help / color / mirror / Atom feed
* [boqun:rust-sync 9/12] arch/mips/kernel/traps.c:2002:2: warning: unused variable 'nesting'
@ 2026-05-06  0:04 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-05-06  0:04 UTC (permalink / raw)
  To: Boqun Feng; +Cc: oe-kbuild-all

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/boqun/linux.git rust-sync
head:   082cc4c201e4450ff9456c9bd093fd70d103595a
commit: 40c3e04e2248c0e5d78d23e6767a1c58d5678eac [9/12] preempt: x86: Avoid tracking NMI separately when 64BIT=y
config: mips-randconfig-r072-20260506 (https://download.01.org/0day-ci/archive/20260506/202605060744.4CMiPCaU-lkp@intel.com/config)
compiler: clang version 23.0.0git (https://github.com/llvm/llvm-project 5bac06718f502014fade905512f1d26d578a18f3)
smatch: v0.5.0-9065-ge9cc34fd
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260506/202605060744.4CMiPCaU-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>
| Closes: https://lore.kernel.org/oe-kbuild-all/202605060744.4CMiPCaU-lkp@intel.com/

All warnings (new ones prefixed by >>):

   arch/mips/kernel/traps.c:1592:17: warning: variable 'prev_state' set but not used [-Wunused-but-set-variable]
    1592 |         enum ctx_state prev_state;
         |                        ^
>> arch/mips/kernel/traps.c:2002:2: warning: unused variable 'nesting' [-Wunused-variable]
    2002 |         nmi_exit();
         |         ^~~~~~~~~~
   include/linux/hardirq.h:164:3: note: expanded from macro 'nmi_exit'
     164 |                 __nmi_exit();                                   \
         |                 ^~~~~~~~~~~~
   include/linux/hardirq.h:150:16: note: expanded from macro '__nmi_exit'
     150 |                 unsigned int nesting;                           \
         |                              ^~~~~~~
   2 warnings generated.


vim +/nesting +2002 arch/mips/kernel/traps.c

34bd92e27becdc Kevin Cernekee  2011-11-16  1990  
ff2d8b19a3a625 Joe Perches     2012-01-12  1991  void __noreturn nmi_exception_handler(struct pt_regs *regs)
^1da177e4c3f41 Linus Torvalds  2005-04-16  1992  {
83e4da1ed45441 Leonid Yegoshin 2013-10-08  1993  	char str[100];
83e4da1ed45441 Leonid Yegoshin 2013-10-08  1994  
7963b3f127a748 Petri Gynther   2015-10-19  1995  	nmi_enter();
34bd92e27becdc Kevin Cernekee  2011-11-16  1996  	raw_notifier_call_chain(&nmi_chain, 0, regs);
41c594ab65fc89 Ralf Baechle    2006-04-05  1997  	bust_spinlocks(1);
83e4da1ed45441 Leonid Yegoshin 2013-10-08  1998  	snprintf(str, 100, "CPU%d NMI taken, CP0_EPC=%lx\n",
83e4da1ed45441 Leonid Yegoshin 2013-10-08  1999  		 smp_processor_id(), regs->cp0_epc);
83e4da1ed45441 Leonid Yegoshin 2013-10-08  2000  	regs->cp0_epc = read_c0_errorepc();
83e4da1ed45441 Leonid Yegoshin 2013-10-08  2001  	die(str, regs);
7963b3f127a748 Petri Gynther   2015-10-19 @2002  	nmi_exit();
^1da177e4c3f41 Linus Torvalds  2005-04-16  2003  }
^1da177e4c3f41 Linus Torvalds  2005-04-16  2004  

:::::: The code at line 2002 was first introduced by commit
:::::: 7963b3f127a7486815bc10639630c95c2792b811 MIPS: add nmi_enter() + nmi_exit() to nmi_exception_handler()

:::::: TO: Petri Gynther <pgynther@google.com>
:::::: CC: Ralf Baechle <ralf@linux-mips.org>

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-05-06  0:05 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-05-06  0:04 [boqun:rust-sync 9/12] arch/mips/kernel/traps.c:2002:2: warning: unused variable 'nesting' kernel test robot

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.