/home/green/git/lustre-release/lnet/lnet/module.c:425:1: error: data definition has no type or storage class [-Werror] __bpf_kfunc_start_defs(); ^~~~~~~~~~~~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:425:1: error: type defaults to ‘int’ in declaration of ‘__bpf_kfunc_start_defs’ [-Werror=implicit-int] /home/green/git/lustre-release/lnet/lnet/module.c:425:1: error: function declaration isn’t a prototype [-Werror=strict-prototypes] /home/green/git/lustre-release/lnet/lnet/module.c:427:12: error: expected ‘;’ before ‘struct’ __bpf_kfunc struct lnet_msg *bpf_lnet_get_msg(struct lnet_msg *msg__ign) ^~~~~~~ ; /home/green/git/lustre-release/lnet/lnet/module.c:437:12: error: expected ‘;’ before ‘void’ __bpf_kfunc void bpf_lnet_put_msg(struct lnet_msg *msg) ^~~~~ ; /home/green/git/lustre-release/lnet/lnet/module.c:445:12: error: expected ‘;’ before ‘void’ __bpf_kfunc void bpf_lnet_load_bytes(void *dest, int dest__sz, ^~~~~ ; /home/green/git/lustre-release/lnet/lnet/module.c:471:12: error: expected ‘;’ before ‘void’ __bpf_kfunc void bpf_lnet_lazy_load_bytes(void *dest, int dest__sz, ^~~~~ ; /home/green/git/lustre-release/lnet/lnet/module.c:483:12: error: expected ‘;’ before ‘void’ __bpf_kfunc void bpf_lnet_ev_load_bytes(void *dest, int dest__sz, ^~~~~ ; /home/green/git/lustre-release/lnet/lnet/module.c:514:1: error: data definition has no type or storage class [-Werror] __bpf_kfunc_end_defs(); ^~~~~~~~~~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:514:1: error: type defaults to ‘int’ in declaration of ‘__bpf_kfunc_end_defs’ [-Werror=implicit-int] /home/green/git/lustre-release/lnet/lnet/module.c:514:1: error: function declaration isn’t a prototype [-Werror=strict-prototypes] /home/green/git/lustre-release/lnet/lnet/module.c:516:1: error: data definition has no type or storage class [-Werror] BTF_KFUNCS_START(bpf_lnet_kfunc_ids); ^~~~~~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:516:1: error: type defaults to ‘int’ in declaration of ‘BTF_KFUNCS_START’ [-Werror=implicit-int] /home/green/git/lustre-release/lnet/lnet/module.c:516:1: error: parameter names (without types) in function declaration [-Werror] /home/green/git/lustre-release/lnet/lnet/module.c:517:48: error: expected ‘)’ before ‘|’ token BTF_ID_FLAGS(func, bpf_lnet_get_msg, KF_ACQUIRE | KF_RET_NULL); ^~ ) /home/green/git/lustre-release/lnet/lnet/module.c:518:1: error: data definition has no type or storage class [-Werror] BTF_ID_FLAGS(func, bpf_lnet_put_msg, KF_RELEASE); ^~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:518:1: error: type defaults to ‘int’ in declaration of ‘BTF_ID_FLAGS’ [-Werror=implicit-int] /home/green/git/lustre-release/lnet/lnet/module.c:518:1: error: parameter names (without types) in function declaration [-Werror] /home/green/git/lustre-release/lnet/lnet/module.c:519:1: error: data definition has no type or storage class [-Werror] BTF_ID_FLAGS(func, bpf_lnet_load_bytes, KF_TRUSTED_ARGS); ^~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:519:1: error: type defaults to ‘int’ in declaration of ‘BTF_ID_FLAGS’ [-Werror=implicit-int] /home/green/git/lustre-release/lnet/lnet/module.c:519:1: error: parameter names (without types) in function declaration [-Werror] /home/green/git/lustre-release/lnet/lnet/module.c:520:1: error: data definition has no type or storage class [-Werror] BTF_ID_FLAGS(func, bpf_lnet_lazy_load_bytes, KF_TRUSTED_ARGS); ^~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:520:1: error: type defaults to ‘int’ in declaration of ‘BTF_ID_FLAGS’ [-Werror=implicit-int] /home/green/git/lustre-release/lnet/lnet/module.c:520:1: error: parameter names (without types) in function declaration [-Werror] /home/green/git/lustre-release/lnet/lnet/module.c:521:43: error: expected ‘)’ before numeric constant BTF_ID_FLAGS(func, bpf_lnet_ev_load_bytes, 0); ^~ ) /home/green/git/lustre-release/lnet/lnet/module.c:522:1: error: data definition has no type or storage class [-Werror] BTF_KFUNCS_END(bpf_lnet_kfunc_ids); ^~~~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:522:1: error: type defaults to ‘int’ in declaration of ‘BTF_KFUNCS_END’ [-Werror=implicit-int] /home/green/git/lustre-release/lnet/lnet/module.c:522:1: error: parameter names (without types) in function declaration [-Werror] /home/green/git/lustre-release/lnet/lnet/module.c:524:21: error: variable ‘bpf_lnet_kfunc_set’ has initializer but incomplete type static const struct btf_kfunc_id_set bpf_lnet_kfunc_set = { ^~~~~~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:525:3: error: ‘const struct btf_kfunc_id_set’ has no member named ‘owner’ .owner = THIS_MODULE, ^~~~~ In file included from ./include/linux/linkage.h:7, from ./include/linux/kernel.h:7, from ./include/linux/list.h:9, from ./include/linux/miscdevice.h:5, from /home/green/git/lustre-release/lnet/lnet/module.c:13: ./include/linux/export.h:29:21: error: excess elements in struct initializer [-Werror] #define THIS_MODULE (&__this_module) ^ /home/green/git/lustre-release/lnet/lnet/module.c:525:11: note: in expansion of macro ‘THIS_MODULE’ .owner = THIS_MODULE, ^~~~~~~~~~~ ./include/linux/export.h:29:21: note: (near initialization for ‘bpf_lnet_kfunc_set’) #define THIS_MODULE (&__this_module) ^ /home/green/git/lustre-release/lnet/lnet/module.c:525:11: note: in expansion of macro ‘THIS_MODULE’ .owner = THIS_MODULE, ^~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:526:3: error: ‘const struct btf_kfunc_id_set’ has no member named ‘set’ .set = &bpf_lnet_kfunc_ids, ^~~ /home/green/git/lustre-release/lnet/lnet/module.c:526:12: error: ‘bpf_lnet_kfunc_ids’ undeclared here (not in a function); did you mean ‘bpf_lnet_kfunc_set’? .set = &bpf_lnet_kfunc_ids, ^~~~~~~~~~~~~~~~~~ bpf_lnet_kfunc_set /home/green/git/lustre-release/lnet/lnet/module.c:526:11: error: excess elements in struct initializer [-Werror] .set = &bpf_lnet_kfunc_ids, ^ /home/green/git/lustre-release/lnet/lnet/module.c:526:11: note: (near initialization for ‘bpf_lnet_kfunc_set’) /home/green/git/lustre-release/lnet/lnet/module.c:529:1: error: data definition has no type or storage class [-Werror] BTF_ID_LIST(bpf_lnet_dtor_ids); ^~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:529:1: error: type defaults to ‘int’ in declaration of ‘BTF_ID_LIST’ [-Werror=implicit-int] /home/green/git/lustre-release/lnet/lnet/module.c:529:1: error: parameter names (without types) in function declaration [-Werror] /home/green/git/lustre-release/lnet/lnet/module.c:530:14: error: expected ‘{’ before ‘,’ token BTF_ID(struct, lnet_msg); ^ /home/green/git/lustre-release/lnet/lnet/module.c:531:1: error: data definition has no type or storage class [-Werror] BTF_ID(func, bpf_lnet_put_msg); ^~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:531:1: error: type defaults to ‘int’ in declaration of ‘BTF_ID’ [-Werror=implicit-int] /home/green/git/lustre-release/lnet/lnet/module.c:531:1: error: parameter names (without types) in function declaration [-Werror] /home/green/git/lustre-release/lnet/lnet/module.c: In function ‘lnet_init’: /home/green/git/lustre-release/lnet/lnet/module.c:536:33: error: array type has incomplete element type ‘struct btf_id_dtor_kfunc’ const struct btf_id_dtor_kfunc bpf_lnet_dtors[] = { ^~~~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:538:4: error: field name not in record or union initializer .btf_id = bpf_lnet_dtor_ids[0], ^ /home/green/git/lustre-release/lnet/lnet/module.c:538:4: note: (near initialization for ‘bpf_lnet_dtors’) /home/green/git/lustre-release/lnet/lnet/module.c:538:15: error: ‘bpf_lnet_dtor_ids’ undeclared (first use in this function); did you mean ‘bpf_lnet_dtors’? .btf_id = bpf_lnet_dtor_ids[0], ^~~~~~~~~~~~~~~~~ bpf_lnet_dtors /home/green/git/lustre-release/lnet/lnet/module.c:538:15: note: each undeclared identifier is reported only once for each function it appears in /home/green/git/lustre-release/lnet/lnet/module.c:539:4: error: field name not in record or union initializer .kfunc_btf_id = bpf_lnet_dtor_ids[1] ^ /home/green/git/lustre-release/lnet/lnet/module.c:539:4: note: (near initialization for ‘bpf_lnet_dtors’) /home/green/git/lustre-release/lnet/lnet/module.c:545:7: error: implicit declaration of function ‘register_btf_kfunc_id_set’; did you mean ‘register_one_node’? [-Werror=implicit-function-declaration] rc = register_btf_kfunc_id_set(BPF_PROG_TYPE_UNSPEC, &bpf_lnet_kfunc_set); ^~~~~~~~~~~~~~~~~~~~~~~~~ register_one_node /home/green/git/lustre-release/lnet/lnet/module.c:549:7: error: implicit declaration of function ‘register_btf_id_dtor_kfuncs’; did you mean ‘register_refined_jiffies’? [-Werror=implicit-function-declaration] rc = register_btf_id_dtor_kfuncs(bpf_lnet_dtors, ^~~~~~~~~~~~~~~~~~~~~~~~~~~ register_refined_jiffies In file included from ./include/linux/container_of.h:5, from ./include/linux/kernel.h:11, from ./include/linux/list.h:9, from ./include/linux/miscdevice.h:5, from /home/green/git/lustre-release/lnet/lnet/module.c:13: ./include/linux/build_bug.h:16:51: error: bit-field ‘’ width not an integer constant #define BUILD_BUG_ON_ZERO(e) ((int)(sizeof(struct { int:(-!!(e)); }))) ^ ./include/linux/compiler.h:469:28: note: in expansion of macro ‘BUILD_BUG_ON_ZERO’ #define __must_be_array(a) BUILD_BUG_ON_ZERO(__same_type((a), &(a)[0])) ^~~~~~~~~~~~~~~~~ ./include/linux/kernel.h:50:59: note: in expansion of macro ‘__must_be_array’ #define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0]) + __must_be_array(arr)) ^~~~~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:550:7: note: in expansion of macro ‘ARRAY_SIZE’ ARRAY_SIZE(bpf_lnet_dtors), ^~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c:536:33: error: unused variable ‘bpf_lnet_dtors’ [-Werror=unused-variable] const struct btf_id_dtor_kfunc bpf_lnet_dtors[] = { ^~~~~~~~~~~~~~ /home/green/git/lustre-release/lnet/lnet/module.c: At top level: /home/green/git/lustre-release/lnet/lnet/module.c:524:38: error: storage size of ‘bpf_lnet_kfunc_set’ isn’t known static const struct btf_kfunc_id_set bpf_lnet_kfunc_set = { ^~~~~~~~~~~~~~~~~~ cc1: all warnings being treated as errors make[6]: *** [scripts/Makefile.build:317: /home/green/git/lustre-release/lnet/lnet/module.o] Error 1 make[6]: *** Waiting for unfinished jobs.... make[5]: *** [scripts/Makefile.build:558: /home/green/git/lustre-release/lnet/lnet] Error 2 make[4]: *** [scripts/Makefile.build:558: /home/green/git/lustre-release/lnet] Error 2 make[3]: *** [Makefile:1619: _module_/home/green/git/lustre-release] Error 2 make[2]: *** [autoMakefile:1235: modules] Error 2 make[1]: *** [autoMakefile:743: all-recursive] Error 1 make: *** [autoMakefile:593: all] Error 2