[openeuler:OLK-5.10 2882/2882] kernel/crash_core.c:380:13: warning: no previous prototype for function 'reserve_crashkernel_high'

tree: https://gitee.com/openeuler/kernel.git OLK-5.10 head: c90dc8f5217147c6c3cfb99d952cfdcaf7e194e1 commit: baac34dd89ca15da7d7f0736fd0e69e13f315ae9 [2882/2882] arm64: kdump: Use page-level mapping for the high memory of crashkernel config: x86_64-randconfig-2002-20250501 (https://download.01.org/0day-ci/archive/20250701/202507011754.bARO1PJL-lkp@i...) compiler: clang version 20.1.2 (https://github.com/llvm/llvm-project 58df0ef89dd64126512e4ee27b4ac3fd8ddf6247) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250701/202507011754.bARO1PJL-lkp@i...) 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/202507011754.bARO1PJL-lkp@intel.com/ All warnings (new ones prefixed by >>):
kernel/crash_core.c:380:13: warning: no previous prototype for function 'reserve_crashkernel_high' [-Wmissing-prototypes] 380 | void __init reserve_crashkernel_high(void) | ^ kernel/crash_core.c:380:1: note: declare 'static' if the function is not intended to be used outside of this translation unit 380 | void __init reserve_crashkernel_high(void) | ^ | static 1 warning generated.
vim +/reserve_crashkernel_high +380 kernel/crash_core.c 379
380 void __init reserve_crashkernel_high(void) 381 { 382 unsigned long long crash_base, crash_size; 383 char *cmdline = boot_command_line; 384 int ret; 385 386 if (!IS_ENABLED(CONFIG_KEXEC_CORE)) 387 return; 388 389 /* crashkernel=X[@offset] */ 390 ret = parse_crashkernel(cmdline, memblock_phys_mem_size(), 391 &crash_size, &crash_base); 392 if (ret || !crash_size) { 393 ret = parse_crashkernel_high(cmdline, 0, &crash_size, &crash_base); 394 if (ret || !crash_size) 395 return; 396 } 397 398 crash_size = PAGE_ALIGN(crash_size); 399 400 /* 401 * For the case crashkernel=X, may fall back to reserve memory above 402 * 4G, make reservations here in advance. It will be released later if 403 * the region is successfully reserved under 4G. 404 */ 405 if (!crash_base) { 406 crash_base = memblock_phys_alloc_range(crash_size, CRASH_ALIGN, 407 crash_base, CRASH_ADDR_HIGH_MAX); 408 if (!crash_base) 409 return; 410 411 crash_high_mem_reserved = true; 412 } 413 414 /* Mark the memory range that requires page-level mappings */ 415 crashk_res.start = crash_base; 416 crashk_res.end = crash_base + crash_size - 1; 417 } 418
-- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
participants (1)
-
kernel test robot