tree: https://gitee.com/openeuler/kernel.git OLK-5.10
head: 220bfa0ea761db9406a3cfde3064aa029e829221
commit: bfeb55fc4d6244f8e7cac9c6d0911cfb67089a35 [2544/2544] livepatch: Reduce duplicated arch_klp_mem_{prepare,recycle}
config: x86_64-randconfig-123-20241205 (https://download.01.org/0day-ci/archive/20241206/202412060112.hYQNEbRS-lkp@…)
compiler: clang version 19.1.3 (https://github.com/llvm/llvm-project ab51eccf88f5321e7c60591c5546b254b6afab99)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241206/202412060112.hYQNEbRS-lkp@…)
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(a)intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202412060112.hYQNEbRS-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from kernel/livepatch/core.c:16:
In file included from include/linux/kallsyms.h:12:
In file included from include/linux/mm.h:1554:
include/linux/vmstat.h:431:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion]
431 | return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
| ~~~~~~~~~~~ ^ ~~~
kernel/livepatch/core.c:68:16: warning: no previous prototype for function 'klp_check_patch_kprobed' [-Wmissing-prototypes]
68 | struct kprobe *klp_check_patch_kprobed(struct klp_patch *patch)
| ^
kernel/livepatch/core.c:68:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
68 | struct kprobe *klp_check_patch_kprobed(struct klp_patch *patch)
| ^
| static
kernel/livepatch/core.c:939:12: warning: no previous prototype for function 'arch_klp_func_can_patch' [-Wmissing-prototypes]
939 | int __weak arch_klp_func_can_patch(struct klp_func *func)
| ^
kernel/livepatch/core.c:939:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
939 | int __weak arch_klp_func_can_patch(struct klp_func *func)
| ^
| static
kernel/livepatch/core.c:944:12: warning: no previous prototype for function 'arch_klp_init_func' [-Wmissing-prototypes]
944 | int __weak arch_klp_init_func(struct klp_object *obj, struct klp_func *func)
| ^
kernel/livepatch/core.c:944:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
944 | int __weak arch_klp_init_func(struct klp_object *obj, struct klp_func *func)
| ^
| static
kernel/livepatch/core.c:1288:5: warning: no previous prototype for function 'klp_try_disable_patch' [-Wmissing-prototypes]
1288 | int klp_try_disable_patch(void *data)
| ^
kernel/livepatch/core.c:1288:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
1288 | int klp_try_disable_patch(void *data)
| ^
| static
kernel/livepatch/core.c:1322:13: warning: no previous prototype for function 'arch_klp_code_modify_prepare' [-Wmissing-prototypes]
1322 | void __weak arch_klp_code_modify_prepare(void)
| ^
kernel/livepatch/core.c:1322:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
1322 | void __weak arch_klp_code_modify_prepare(void)
| ^
| static
kernel/livepatch/core.c:1326:13: warning: no previous prototype for function 'arch_klp_code_modify_post_process' [-Wmissing-prototypes]
1326 | void __weak arch_klp_code_modify_post_process(void)
| ^
kernel/livepatch/core.c:1326:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
1326 | void __weak arch_klp_code_modify_post_process(void)
| ^
| static
>> kernel/livepatch/core.c:1330:14: warning: no previous prototype for function 'arch_klp_mem_alloc' [-Wmissing-prototypes]
1330 | void __weak *arch_klp_mem_alloc(size_t size)
| ^
kernel/livepatch/core.c:1330:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
1330 | void __weak *arch_klp_mem_alloc(size_t size)
| ^
| static
>> kernel/livepatch/core.c:1335:13: warning: no previous prototype for function 'arch_klp_mem_free' [-Wmissing-prototypes]
1335 | void __weak arch_klp_mem_free(void *mem)
| ^
kernel/livepatch/core.c:1335:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
1335 | void __weak arch_klp_mem_free(void *mem)
| ^
| static
kernel/livepatch/core.c:1573:5: warning: no previous prototype for function 'klp_try_enable_patch' [-Wmissing-prototypes]
1573 | int klp_try_enable_patch(void *data)
| ^
kernel/livepatch/core.c:1573:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
1573 | int klp_try_enable_patch(void *data)
| ^
| static
10 warnings generated.
vim +/arch_klp_mem_alloc +1330 kernel/livepatch/core.c
1329
> 1330 void __weak *arch_klp_mem_alloc(size_t size)
1331 {
1332 return kzalloc(size, GFP_ATOMIC);
1333 }
1334
> 1335 void __weak arch_klp_mem_free(void *mem)
1336 {
1337 kfree(mem);
1338 }
1339
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Hi Jason,
FYI, the error/warning still remains.
tree: https://gitee.com/openeuler/kernel.git openEuler-1.0-LTS
head: d05ffd830132e58bd394d5e8123765b9037141b2
commit: d856ec500c97835c591ffacc005f514509f1a931 [1321/1321] scsi: libsas: check if the same sata device when flutter
config: x86_64-buildonly-randconfig-005-20241205 (https://download.01.org/0day-ci/archive/20241205/202412051729.ejnzHbRm-lkp@…)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241205/202412051729.ejnzHbRm-lkp@…)
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(a)intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202412051729.ejnzHbRm-lkp@intel.com/
All errors (new ones prefixed by >>):
ld: warning: arch/x86/lib/csum-copy_64.o: missing .note.GNU-stack section implies executable stack
ld: NOTE: This behaviour is deprecated and will be removed in a future version of the linker
ld: warning: arch/x86/lib/csum-copy_64.o: missing .note.GNU-stack section implies executable stack
ld: NOTE: This behaviour is deprecated and will be removed in a future version of the linker
ld: warning: .tmp_vmlinux1 has a LOAD segment with RWX permissions
ld: drivers/scsi/libsas/sas_expander.o: in function `sas_rediscover_dev':
>> sas_expander.c:(.text.unlikely+0x3f4): undefined reference to `ata_dev_same_device'
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki