Hi Qiang, kernel test robot noticed the following build warnings:
[auto build test WARNING on akpm-mm/mm-everything] [also build test WARNING on linus/master v6.18-rc3 next-20251030] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch#_base_tree_information] url: https://github.com/intel-lab-lkp/linux/commits/Qiang-Ma/kexec-print-out-debugging-message-if-required-for-kexec_load/20251030-153807 base: https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything patch link: https://lore.kernel.org/r/20251030073316.529106-1-maqianga%40uniontech.com patch subject: [PATCH] kexec: print out debugging message if required for kexec_load config: x86_64-kexec (https://download.01.org/0day-ci/archive/20251031/[email protected]/config) compiler: clang version 20.1.8 (https://github.com/llvm/llvm-project 87f0227cb60147a26a1eeb4fb06e3b505e9c7261) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251031/[email protected]/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 <[email protected]> | Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/ All warnings (new ones prefixed by >>): >> kernel/kexec.c:160:10: warning: format specifies type 'int' but the argument >> has type 'unsigned long' [-Wformat] 159 | kexec_dprintk("segment[%d]: buf=0x%p bufsz=0x%zx mem=0x%lx memsz=0x%zx\n", | ~~ | %lu 160 | i, ksegment->buf, ksegment->bufsz, ksegment->mem, | ^ include/linux/kexec.h:531:55: note: expanded from macro 'kexec_dprintk' 531 | do { if (kexec_file_dbg_print) pr_info(fmt, ##arg); } while (0) | ~~~ ^~~ include/linux/printk.h:585:34: note: expanded from macro 'pr_info' 585 | printk(KERN_INFO pr_fmt(fmt), ##__VA_ARGS__) | ~~~ ^~~~~~~~~~~ include/linux/printk.h:512:60: note: expanded from macro 'printk' 512 | #define printk(fmt, ...) printk_index_wrap(_printk, fmt, ##__VA_ARGS__) | ~~~ ^~~~~~~~~~~ include/linux/printk.h:484:19: note: expanded from macro 'printk_index_wrap' 484 | _p_func(_fmt, ##__VA_ARGS__); \ | ~~~~ ^~~~~~~~~~~ 1 warning generated. vim +160 kernel/kexec.c 141 142 ret = machine_kexec_prepare(image); 143 if (ret) 144 goto out; 145 146 /* 147 * Some architecture(like S390) may touch the crash memory before 148 * machine_kexec_prepare(), we must copy vmcoreinfo data after it. 149 */ 150 ret = kimage_crash_copy_vmcoreinfo(image); 151 if (ret) 152 goto out; 153 154 kexec_dprintk("nr_segments = %lu\n", image->nr_segments); 155 for (i = 0; i < nr_segments; i++) { 156 struct kexec_segment *ksegment; 157 158 ksegment = &image->segment[i]; 159 kexec_dprintk("segment[%d]: buf=0x%p bufsz=0x%zx mem=0x%lx memsz=0x%zx\n", > 160 i, ksegment->buf, ksegment->bufsz, > ksegment->mem, 161 ksegment->memsz); 162 163 ret = kimage_load_segment(image, i); 164 if (ret) 165 goto out; 166 } 167 168 kimage_terminate(image); 169 170 ret = machine_kexec_post_load(image); 171 if (ret) 172 goto out; 173 174 kexec_dprintk("kexec_file_load: type:%u, start:0x%lx head:0x%lx flags:0x%lx\n", 175 image->type, image->start, image->head, flags); 176 177 /* Install the new kernel and uninstall the old */ 178 image = xchg(dest_image, image); 179 180 out: 181 #ifdef CONFIG_CRASH_DUMP 182 if ((flags & KEXEC_ON_CRASH) && kexec_crash_image) 183 arch_kexec_protect_crashkres(); 184 #endif 185 186 kimage_free(image); 187 out_unlock: 188 kexec_unlock(); 189 return ret; 190 } 191 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki
