[linux-next:master 4353/4884] arch/mips/kernel/machine_kexec.c:76:17: error: 'kexec_args' undeclared

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   0f5f12ac05f36f117e793656c3f560625e927f1b
commit: 4fa0ee5b7e2ddb44036b40795ca4a79d94edc7d4 [4353/4884] kexec_core: change dependency of object files
config: mips-randconfig-r032-20220731 (https://download.01.org/0day-ci/archive/20231206/202312061137.QgjJ4nTc-lkp@xxxxxxxxx/config)
compiler: mipsel-linux-gcc (GCC) 13.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231206/202312061137.QgjJ4nTc-lkp@xxxxxxxxx/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@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202312061137.QgjJ4nTc-lkp@xxxxxxxxx/

All errors (new ones prefixed by >>):

   arch/mips/kernel/machine_kexec.c: In function 'uhi_machine_kexec_prepare':
>> arch/mips/kernel/machine_kexec.c:76:17: error: 'kexec_args' undeclared (first use in this function)
      76 |                 kexec_args[0] = -2;
         |                 ^~~~~~~~~~
   arch/mips/kernel/machine_kexec.c:76:17: note: each undeclared identifier is reported only once for each function it appears in
   arch/mips/kernel/machine_kexec.c: In function 'machine_kexec_prepare':
   arch/mips/kernel/machine_kexec.c:97:14: error: implicit declaration of function 'kexec_nonboot_cpu_func' [-Werror=implicit-function-declaration]
      97 |         if (!kexec_nonboot_cpu_func())
         |              ^~~~~~~~~~~~~~~~~~~~~~
   arch/mips/kernel/machine_kexec.c: In function 'kexec_shutdown_secondary':
   arch/mips/kernel/machine_kexec.c:129:9: error: implicit declaration of function 'kexec_reboot' [-Werror=implicit-function-declaration]
     129 |         kexec_reboot();
         |         ^~~~~~~~~~~~
   arch/mips/kernel/machine_kexec.c: At top level:
   arch/mips/kernel/machine_kexec.c:136:1: warning: no previous prototype for 'machine_shutdown' [-Wmissing-prototypes]
     136 | machine_shutdown(void)
         | ^~~~~~~~~~~~~~~~
   arch/mips/kernel/machine_kexec.c:152:1: warning: no previous prototype for 'machine_crash_shutdown' [-Wmissing-prototypes]
     152 | machine_crash_shutdown(struct pt_regs *regs)
         | ^~~~~~~~~~~~~~~~~~~~~~
   arch/mips/kernel/machine_kexec.c: In function 'machine_crash_shutdown':
   arch/mips/kernel/machine_kexec.c:157:17: error: implicit declaration of function 'default_machine_crash_shutdown'; did you mean '_machine_crash_shutdown'? [-Werror=implicit-function-declaration]
     157 |                 default_machine_crash_shutdown(regs);
         |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
         |                 _machine_crash_shutdown
   arch/mips/kernel/machine_kexec.c: At top level:
   arch/mips/kernel/machine_kexec.c:161:6: warning: no previous prototype for 'kexec_nonboot_cpu_jump' [-Wmissing-prototypes]
     161 | void kexec_nonboot_cpu_jump(void)
         |      ^~~~~~~~~~~~~~~~~~~~~~
   arch/mips/kernel/machine_kexec.c:170:6: warning: no previous prototype for 'kexec_reboot' [-Wmissing-prototypes]
     170 | void kexec_reboot(void)
         |      ^~~~~~~~~~~~
   arch/mips/kernel/machine_kexec.c:170:6: warning: conflicting types for 'kexec_reboot'; have 'void(void)'
   arch/mips/kernel/machine_kexec.c:129:9: note: previous implicit declaration of 'kexec_reboot' with type 'void(void)'
     129 |         kexec_reboot();
         |         ^~~~~~~~~~~~
   arch/mips/kernel/machine_kexec.c: In function 'kexec_reboot':
   arch/mips/kernel/machine_kexec.c:191:17: error: implicit declaration of function 'kexec_nonboot_cpu'; did you mean 'kexec_nonboot_cpu_jump'? [-Werror=implicit-function-declaration]
     191 |                 kexec_nonboot_cpu();
         |                 ^~~~~~~~~~~~~~~~~
         |                 kexec_nonboot_cpu_jump
   arch/mips/kernel/machine_kexec.c: In function 'machine_kexec':
   arch/mips/kernel/machine_kexec.c:259:26: error: 'kexec_smp_wait' undeclared (first use in this function)
     259 |                 (void *)(kexec_smp_wait - relocate_new_kernel);
         |                          ^~~~~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/kexec_args +76 arch/mips/kernel/machine_kexec.c

2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  54  
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  55  static int uhi_machine_kexec_prepare(struct kimage *kimage)
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  56  {
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  57  	int i;
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  58  
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  59  	/*
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  60  	 * In case DTB file is not passed to the new kernel, a flat device
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  61  	 * tree will be created by kexec tool. It holds modified command
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  62  	 * line for the new kernel.
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  63  	 */
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  64  	for (i = 0; i < kimage->nr_segments; i++) {
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  65  		struct fdt_header fdt;
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  66  
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  67  		if (kimage->segment[i].memsz <= sizeof(fdt))
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  68  			continue;
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  69  
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  70  		if (copy_from_user(&fdt, kimage->segment[i].buf, sizeof(fdt)))
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  71  			continue;
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  72  
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  73  		if (fdt_check_header(&fdt))
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  74  			continue;
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  75  
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11 @76  		kexec_args[0] = -2;
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  77  		kexec_args[1] = (unsigned long)
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  78  			phys_to_virt((unsigned long)kimage->segment[i].mem);
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  79  		break;
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  80  	}
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  81  
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  82  	return 0;
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  83  }
2fe8ea39c9a848 Dengcheng Zhu 2018-09-11  84  

:::::: The code at line 76 was first introduced by commit
:::::: 2fe8ea39c9a8489799cf86bb377fc80492b5b3bf MIPS: kexec: Use prepare method from Generic for UHI platforms

:::::: TO: Dengcheng Zhu <dzhu@xxxxxxxxxxxx>
:::::: CC: Paul Burton <paul.burton@xxxxxxxx>

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




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux