Re: [PATCH v5 01/16] kexec: define functions to map and unmap segments
From: kernel test robot
Date: Thu Mar 20 2025 - 10:17:14 EST
Hi Changyuan,
kernel test robot noticed the following build warnings:
[auto build test WARNING on a7f2e10ecd8f18b83951b0bab47ddaf48f93bf47]
url: https://github.com/intel-lab-lkp/linux/commits/Changyuan-Lyu/kexec-define-functions-to-map-and-unmap-segments/20250320-095900
base: a7f2e10ecd8f18b83951b0bab47ddaf48f93bf47
patch link: https://lore.kernel.org/r/20250320015551.2157511-2-changyuanl%40google.com
patch subject: [PATCH v5 01/16] kexec: define functions to map and unmap segments
config: i386-buildonly-randconfig-002-20250320 (https://download.01.org/0day-ci/archive/20250320/202503202151.vHOV0UKU-lkp@xxxxxxxxx/config)
compiler: clang version 20.1.1 (https://github.com/llvm/llvm-project 424c2d9b7e4de40d0804dd374721e6411c27d1d1)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250320/202503202151.vHOV0UKU-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/202503202151.vHOV0UKU-lkp@xxxxxxxxx/
All warnings (new ones prefixed by >>):
In file included from kernel/reboot.c:13:
>> include/linux/kexec.h:479:47: warning: declaration of 'struct kimage' will not be visible outside of this function [-Wvisibility]
479 | static inline void *kimage_map_segment(struct kimage *image, unsigned long addr, unsigned long size)
| ^
1 warning generated.
vim +479 include/linux/kexec.h
466
467 #define kexec_dprintk(fmt, arg...) \
468 do { if (kexec_file_dbg_print) pr_info(fmt, ##arg); } while (0)
469
470 void *kimage_map_segment(struct kimage *image, unsigned long addr, unsigned long size);
471 void kimage_unmap_segment(void *buffer);
472 #else /* !CONFIG_KEXEC_CORE */
473 struct pt_regs;
474 struct task_struct;
475 static inline void __crash_kexec(struct pt_regs *regs) { }
476 static inline void crash_kexec(struct pt_regs *regs) { }
477 static inline int kexec_should_crash(struct task_struct *p) { return 0; }
478 static inline int kexec_crash_loaded(void) { return 0; }
> 479 static inline void *kimage_map_segment(struct kimage *image, unsigned long addr, unsigned long size)
480 { return NULL; }
481 static inline void kimage_unmap_segment(void *buffer) { }
482 #define kexec_in_progress false
483 #endif /* CONFIG_KEXEC_CORE */
484
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki