tree:
https://github.com/0day-ci/linux/commits/UPDATE-20200221-182711/Peter-Zij...
head: f4dfc8a95f29bf28eda9253734e8f6ffdc0c3d97
commit: 6d6e966e8cdfa647eb598e266414c176f6749010 [1/22] hardirq/nmi: Allow nested
nmi_enter()
config: powerpc-mpc8313_rdb_defconfig (attached as .config)
compiler: powerpc-linux-gcc (GCC) 7.5.0
reproduce:
wget
https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O
~/bin/make.cross
chmod +x ~/bin/make.cross
git checkout 6d6e966e8cdfa647eb598e266414c176f6749010
# save the attached .config to linux build tree
GCC_VERSION=7.5.0 make.cross ARCH=powerpc
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
arch/powerpc/kernel/traps.c: In function 'machine_check_exception':
> arch/powerpc/kernel/traps.c:846:7: error: 'nested'
undeclared (first use in this function); did you mean 'net'?
if
(!nested)
^~~~~~
net
arch/powerpc/kernel/traps.c:846:7: note: each undeclared identifier is reported only
once for each function it appears in
vim +846 arch/powerpc/kernel/traps.c
75918a4b5998c9 Olof Johansson 2007-09-21 815
75918a4b5998c9 Olof Johansson 2007-09-21 816 void machine_check_exception(struct
pt_regs *regs)
75918a4b5998c9 Olof Johansson 2007-09-21 817 {
75918a4b5998c9 Olof Johansson 2007-09-21 818 int recover = 0;
6d6e966e8cdfa6 Peter Zijlstra 2020-02-19 819
b96672dd840f22 Nicholas Piggin 2017-07-19 820 nmi_enter();
75918a4b5998c9 Olof Johansson 2007-09-21 821
69111bac42f5ce Christoph Lameter 2014-10-21 822
__this_cpu_inc(irq_stat.mce_exceptions);
89713ed1081540 Anton Blanchard 2010-01-31 823
d93b0ac01a9ce2 Mahesh Salgaonkar 2017-04-18 824 add_taint(TAINT_MACHINE_CHECK,
LOCKDEP_NOW_UNRELIABLE);
d93b0ac01a9ce2 Mahesh Salgaonkar 2017-04-18 825
47c0bd1ae24c34 Benjamin Herrenschmidt 2007-12-21 826 /* See if any machine dependent
calls. In theory, we would want
47c0bd1ae24c34 Benjamin Herrenschmidt 2007-12-21 827 * to call the CPU first, and call
the ppc_md. one if the CPU
47c0bd1ae24c34 Benjamin Herrenschmidt 2007-12-21 828 * one returns a positive number.
However there is existing code
47c0bd1ae24c34 Benjamin Herrenschmidt 2007-12-21 829 * that assumes the board gets a
first chance, so let's keep it
47c0bd1ae24c34 Benjamin Herrenschmidt 2007-12-21 830 * that way for now and fix things
later. --BenH.
47c0bd1ae24c34 Benjamin Herrenschmidt 2007-12-21 831 */
75918a4b5998c9 Olof Johansson 2007-09-21 832 if
(ppc_md.machine_check_exception)
75918a4b5998c9 Olof Johansson 2007-09-21 833 recover =
ppc_md.machine_check_exception(regs);
47c0bd1ae24c34 Benjamin Herrenschmidt 2007-12-21 834 else if
(cur_cpu_spec->machine_check)
47c0bd1ae24c34 Benjamin Herrenschmidt 2007-12-21 835 recover =
cur_cpu_spec->machine_check(regs);
75918a4b5998c9 Olof Johansson 2007-09-21 836
47c0bd1ae24c34 Benjamin Herrenschmidt 2007-12-21 837 if (recover > 0)
ba12eedee321ee Li Zhong 2013-05-13 838 goto bail;
75918a4b5998c9 Olof Johansson 2007-09-21 839
a443506b8598bb Anton Blanchard 2011-01-11 840 if (debugger_fault_handler(regs))
ba12eedee321ee Li Zhong 2013-05-13 841 goto bail;
75918a4b5998c9 Olof Johansson 2007-09-21 842
75918a4b5998c9 Olof Johansson 2007-09-21 843 if (check_io_access(regs))
ba12eedee321ee Li Zhong 2013-05-13 844 goto bail;
75918a4b5998c9 Olof Johansson 2007-09-21 845
daf00ae71dad8a Christophe Leroy 2018-10-13 @846 if (!nested)
daf00ae71dad8a Christophe Leroy 2018-10-13 847 nmi_exit();
daf00ae71dad8a Christophe Leroy 2018-10-13 848
daf00ae71dad8a Christophe Leroy 2018-10-13 849 die("Machine check",
regs, SIGBUS);
daf00ae71dad8a Christophe Leroy 2018-10-13 850
0bbea75c476b77 Christophe Leroy 2019-01-22 851 /* Must die if the interrupt is
not recoverable */
0bbea75c476b77 Christophe Leroy 2019-01-22 852 if (!(regs->msr & MSR_RI))
0bbea75c476b77 Christophe Leroy 2019-01-22 853 nmi_panic(regs,
"Unrecoverable Machine check");
0bbea75c476b77 Christophe Leroy 2019-01-22 854
daf00ae71dad8a Christophe Leroy 2018-10-13 855 return;
daf00ae71dad8a Christophe Leroy 2018-10-13 856
ba12eedee321ee Li Zhong 2013-05-13 857 bail:
b96672dd840f22 Nicholas Piggin 2017-07-19 858 nmi_exit();
14cf11af6cf608 Paul Mackerras 2005-09-26 859 }
14cf11af6cf608 Paul Mackerras 2005-09-26 860
:::::: The code at line 846 was first introduced by commit
:::::: daf00ae71dad8aa05965713c62558aeebf2df48e powerpc/traps: restore recoverability of
machine_check interrupts
:::::: TO: Christophe Leroy <christophe.leroy(a)c-s.fr>
:::::: CC: Michael Ellerman <mpe(a)ellerman.id.au>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org