Messages in this thread | | | Date | Sun, 20 Jun 2021 08:13:40 +0800 | From | kernel test robot <> | Subject | [tip:smp/urgent 1/1] kernel/cpu.c:1353:2: error: implicit declaration of function 'cpu_up_down_serialize_trainwrecks' |
| |
tree: https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git smp/urgent head: 64c71be97c02c3d3f24dea7c290912ad300538b9 commit: 64c71be97c02c3d3f24dea7c290912ad300538b9 [1/1] cpu/hotplug: Cure the cpusets trainwreck config: riscv-randconfig-r031-20210620 (attached as .config) compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project d1baf2895467735ab14f4b3415fce204c0cc8e7f) reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # install riscv cross compiling tool for clang build # apt-get install binutils-riscv64-linux-gnu # https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git/commit/?id=64c71be97c02c3d3f24dea7c290912ad300538b9 git remote add tip https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git git fetch --no-tags tip smp/urgent git checkout 64c71be97c02c3d3f24dea7c290912ad300538b9 # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=riscv
If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
In file included from arch/riscv/include/asm/io.h:149: include/asm-generic/io.h:556:9: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] return inb(addr); ^~~~~~~~~ arch/riscv/include/asm/io.h:55:76: note: expanded from macro 'inb' #define inb(c) ({ u8 __v; __io_pbr(); __v = readb_cpu((void*)(PCI_IOBASE + (c))); __io_par(__v); __v; }) ~~~~~~~~~~ ^ arch/riscv/include/asm/mmio.h:87:48: note: expanded from macro 'readb_cpu' #define readb_cpu(c) ({ u8 __r = __raw_readb(c); __r; }) ^ In file included from kernel/cpu.c:13: In file included from include/linux/sched/isolation.h:6: In file included from include/linux/tick.h:8: In file included from include/linux/clockchips.h:14: In file included from include/linux/clocksource.h:22: In file included from arch/riscv/include/asm/io.h:149: include/asm-generic/io.h:564:9: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] return inw(addr); ^~~~~~~~~ arch/riscv/include/asm/io.h:56:76: note: expanded from macro 'inw' #define inw(c) ({ u16 __v; __io_pbr(); __v = readw_cpu((void*)(PCI_IOBASE + (c))); __io_par(__v); __v; }) ~~~~~~~~~~ ^ arch/riscv/include/asm/mmio.h:88:76: note: expanded from macro 'readw_cpu' #define readw_cpu(c) ({ u16 __r = le16_to_cpu((__force __le16)__raw_readw(c)); __r; }) ^ include/uapi/linux/byteorder/little_endian.h:36:51: note: expanded from macro '__le16_to_cpu' #define __le16_to_cpu(x) ((__force __u16)(__le16)(x)) ^ In file included from kernel/cpu.c:13: In file included from include/linux/sched/isolation.h:6: In file included from include/linux/tick.h:8: In file included from include/linux/clockchips.h:14: In file included from include/linux/clocksource.h:22: In file included from arch/riscv/include/asm/io.h:149: include/asm-generic/io.h:572:9: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] return inl(addr); ^~~~~~~~~ arch/riscv/include/asm/io.h:57:76: note: expanded from macro 'inl' #define inl(c) ({ u32 __v; __io_pbr(); __v = readl_cpu((void*)(PCI_IOBASE + (c))); __io_par(__v); __v; }) ~~~~~~~~~~ ^ arch/riscv/include/asm/mmio.h:89:76: note: expanded from macro 'readl_cpu' #define readl_cpu(c) ({ u32 __r = le32_to_cpu((__force __le32)__raw_readl(c)); __r; }) ^ include/uapi/linux/byteorder/little_endian.h:34:51: note: expanded from macro '__le32_to_cpu' #define __le32_to_cpu(x) ((__force __u32)(__le32)(x)) ^ In file included from kernel/cpu.c:13: In file included from include/linux/sched/isolation.h:6: In file included from include/linux/tick.h:8: In file included from include/linux/clockchips.h:14: In file included from include/linux/clocksource.h:22: In file included from arch/riscv/include/asm/io.h:149: include/asm-generic/io.h:580:2: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] outb(value, addr); ^~~~~~~~~~~~~~~~~ arch/riscv/include/asm/io.h:59:68: note: expanded from macro 'outb' #define outb(v,c) ({ __io_pbw(); writeb_cpu((v),(void*)(PCI_IOBASE + (c))); __io_paw(); }) ~~~~~~~~~~ ^ arch/riscv/include/asm/mmio.h:91:52: note: expanded from macro 'writeb_cpu' #define writeb_cpu(v, c) ((void)__raw_writeb((v), (c))) ^ In file included from kernel/cpu.c:13: In file included from include/linux/sched/isolation.h:6: In file included from include/linux/tick.h:8: In file included from include/linux/clockchips.h:14: In file included from include/linux/clocksource.h:22: In file included from arch/riscv/include/asm/io.h:149: include/asm-generic/io.h:588:2: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] outw(value, addr); ^~~~~~~~~~~~~~~~~ arch/riscv/include/asm/io.h:60:68: note: expanded from macro 'outw' #define outw(v,c) ({ __io_pbw(); writew_cpu((v),(void*)(PCI_IOBASE + (c))); __io_paw(); }) ~~~~~~~~~~ ^ arch/riscv/include/asm/mmio.h:92:76: note: expanded from macro 'writew_cpu' #define writew_cpu(v, c) ((void)__raw_writew((__force u16)cpu_to_le16(v), (c))) ^ In file included from kernel/cpu.c:13: In file included from include/linux/sched/isolation.h:6: In file included from include/linux/tick.h:8: In file included from include/linux/clockchips.h:14: In file included from include/linux/clocksource.h:22: In file included from arch/riscv/include/asm/io.h:149: include/asm-generic/io.h:596:2: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] outl(value, addr); ^~~~~~~~~~~~~~~~~ arch/riscv/include/asm/io.h:61:68: note: expanded from macro 'outl' #define outl(v,c) ({ __io_pbw(); writel_cpu((v),(void*)(PCI_IOBASE + (c))); __io_paw(); }) ~~~~~~~~~~ ^ arch/riscv/include/asm/mmio.h:93:76: note: expanded from macro 'writel_cpu' #define writel_cpu(v, c) ((void)__raw_writel((__force u32)cpu_to_le32(v), (c))) ^ In file included from kernel/cpu.c:13: In file included from include/linux/sched/isolation.h:6: In file included from include/linux/tick.h:8: In file included from include/linux/clockchips.h:14: In file included from include/linux/clocksource.h:22: In file included from arch/riscv/include/asm/io.h:149: include/asm-generic/io.h:1024:55: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic] return (port > MMIO_UPPER_LIMIT) ? NULL : PCI_IOBASE + port; ~~~~~~~~~~ ^ >> kernel/cpu.c:1353:2: error: implicit declaration of function 'cpu_up_down_serialize_trainwrecks' [-Werror,-Wimplicit-function-declaration] cpu_up_down_serialize_trainwrecks(tasks_frozen); ^ 7 warnings and 1 error generated.
Kconfig warnings: (for reference only) WARNING: unmet direct dependencies detected for LOCKDEP Depends on DEBUG_KERNEL && LOCK_DEBUGGING_SUPPORT && (FRAME_POINTER || MIPS || PPC || S390 || MICROBLAZE || ARM || ARC || X86) Selected by - PROVE_LOCKING && DEBUG_KERNEL && LOCK_DEBUGGING_SUPPORT - LOCK_STAT && DEBUG_KERNEL && LOCK_DEBUGGING_SUPPORT - DEBUG_LOCK_ALLOC && DEBUG_KERNEL && LOCK_DEBUGGING_SUPPORT
vim +/cpu_up_down_serialize_trainwrecks +1353 kernel/cpu.c
1295 1296 /* Requires cpu_add_remove_lock to be held */ 1297 static int _cpu_up(unsigned int cpu, int tasks_frozen, enum cpuhp_state target) 1298 { 1299 struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu); 1300 struct task_struct *idle; 1301 int ret = 0; 1302 1303 cpus_write_lock(); 1304 1305 if (!cpu_present(cpu)) { 1306 ret = -EINVAL; 1307 goto out; 1308 } 1309 1310 /* 1311 * The caller of cpu_up() might have raced with another 1312 * caller. Nothing to do. 1313 */ 1314 if (st->state >= target) 1315 goto out; 1316 1317 if (st->state == CPUHP_OFFLINE) { 1318 /* Let it fail before we try to bring the cpu up */ 1319 idle = idle_thread_get(cpu); 1320 if (IS_ERR(idle)) { 1321 ret = PTR_ERR(idle); 1322 goto out; 1323 } 1324 } 1325 1326 cpuhp_tasks_frozen = tasks_frozen; 1327 1328 cpuhp_set_state(st, target); 1329 /* 1330 * If the current CPU state is in the range of the AP hotplug thread, 1331 * then we need to kick the thread once more. 1332 */ 1333 if (st->state > CPUHP_BRINGUP_CPU) { 1334 ret = cpuhp_kick_ap_work(cpu); 1335 /* 1336 * The AP side has done the error rollback already. Just 1337 * return the error code.. 1338 */ 1339 if (ret) 1340 goto out; 1341 } 1342 1343 /* 1344 * Try to reach the target state. We max out on the BP at 1345 * CPUHP_BRINGUP_CPU. After that the AP hotplug thread is 1346 * responsible for bringing it up to the target state. 1347 */ 1348 target = min((int)target, CPUHP_BRINGUP_CPU); 1349 ret = cpuhp_up_callbacks(cpu, st, target); 1350 out: 1351 cpus_write_unlock(); 1352 arch_smt_update(); > 1353 cpu_up_down_serialize_trainwrecks(tasks_frozen); 1354 return ret; 1355 } 1356
--- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org [unhandled content-type:application/gzip] | |