* kernel/module.c:4478:14: warning: variable 'exit' set but not used
@ 2021-11-26 1:55 kernel test robot
0 siblings, 0 replies; 4+ messages in thread
From: kernel test robot @ 2021-11-26 1:55 UTC (permalink / raw)
To: Arnd Bergmann
Cc: llvm, kbuild-all, linux-kernel, Jessica Yu, Sami Tolvanen,
Miroslav Benes
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 8ced7ca3570333998ad2088d5a6275701970e28e
commit: 0d67e332e6df72f43eaa21228daa3a79e23093f3 module: fix clang CFI with MODULE_UNLOAD=n
date: 8 weeks ago
config: arm64-randconfig-r015-20211123 (https://download.01.org/0day-ci/archive/20211126/202111260932.G88s9JDN-lkp@intel.com/config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 49e3838145dff1ec91c2e67a2cb562775c8d2a08)
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 arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0d67e332e6df72f43eaa21228daa3a79e23093f3
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 0d67e332e6df72f43eaa21228daa3a79e23093f3
# save the config file to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> kernel/module.c:4478:14: warning: variable 'exit' set but not used [-Wunused-but-set-variable]
exitcall_t *exit;
^
1 warning generated.
vim +/exit +4478 kernel/module.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 4473
cf68fffb66d60d Sami Tolvanen 2021-04-08 4474 static void cfi_init(struct module *mod)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4475 {
cf68fffb66d60d Sami Tolvanen 2021-04-08 4476 #ifdef CONFIG_CFI_CLANG
cf68fffb66d60d Sami Tolvanen 2021-04-08 4477 initcall_t *init;
cf68fffb66d60d Sami Tolvanen 2021-04-08 @4478 exitcall_t *exit;
cf68fffb66d60d Sami Tolvanen 2021-04-08 4479
cf68fffb66d60d Sami Tolvanen 2021-04-08 4480 rcu_read_lock_sched();
cf68fffb66d60d Sami Tolvanen 2021-04-08 4481 mod->cfi_check = (cfi_check_fn)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4482 find_kallsyms_symbol_value(mod, "__cfi_check");
cf68fffb66d60d Sami Tolvanen 2021-04-08 4483 init = (initcall_t *)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4484 find_kallsyms_symbol_value(mod, "__cfi_jt_init_module");
cf68fffb66d60d Sami Tolvanen 2021-04-08 4485 exit = (exitcall_t *)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4486 find_kallsyms_symbol_value(mod, "__cfi_jt_cleanup_module");
cf68fffb66d60d Sami Tolvanen 2021-04-08 4487 rcu_read_unlock_sched();
cf68fffb66d60d Sami Tolvanen 2021-04-08 4488
cf68fffb66d60d Sami Tolvanen 2021-04-08 4489 /* Fix init/exit functions to point to the CFI jump table */
cf68fffb66d60d Sami Tolvanen 2021-04-08 4490 if (init)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4491 mod->init = *init;
0d67e332e6df72 Arnd Bergmann 2021-09-27 4492 #ifdef CONFIG_MODULE_UNLOAD
cf68fffb66d60d Sami Tolvanen 2021-04-08 4493 if (exit)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4494 mod->exit = *exit;
0d67e332e6df72 Arnd Bergmann 2021-09-27 4495 #endif
cf68fffb66d60d Sami Tolvanen 2021-04-08 4496
cf68fffb66d60d Sami Tolvanen 2021-04-08 4497 cfi_module_add(mod, module_addr_min);
cf68fffb66d60d Sami Tolvanen 2021-04-08 4498 #endif
cf68fffb66d60d Sami Tolvanen 2021-04-08 4499 }
cf68fffb66d60d Sami Tolvanen 2021-04-08 4500
:::::: The code at line 4478 was first introduced by commit
:::::: cf68fffb66d60d96209446bfc4a15291dc5a5d41 add support for Clang CFI
:::::: TO: Sami Tolvanen <samitolvanen@google.com>
:::::: CC: Kees Cook <keescook@chromium.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
^ permalink raw reply [flat|nested] 4+ messages in thread
* kernel/module.c:4478:14: warning: variable 'exit' set but not used
@ 2022-02-28 6:09 kernel test robot
0 siblings, 0 replies; 4+ messages in thread
From: kernel test robot @ 2022-02-28 6:09 UTC (permalink / raw)
To: Arnd Bergmann
Cc: llvm, kbuild-all, linux-kernel, Jessica Yu, Sami Tolvanen,
Miroslav Benes
Hi Arnd,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 7e57714cd0ad2d5bb90e50b5096a0e671dec1ef3
commit: 0d67e332e6df72f43eaa21228daa3a79e23093f3 module: fix clang CFI with MODULE_UNLOAD=n
date: 5 months ago
config: arm64-buildonly-randconfig-r001-20220228 (https://download.01.org/0day-ci/archive/20220228/202202281419.BQ8frGhi-lkp@intel.com/config)
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project d271fc04d5b97b12e6b797c6067d3c96a8d7470e)
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 arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0d67e332e6df72f43eaa21228daa3a79e23093f3
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 0d67e332e6df72f43eaa21228daa3a79e23093f3
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm64 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> kernel/module.c:4478:14: warning: variable 'exit' set but not used [-Wunused-but-set-variable]
exitcall_t *exit;
^
kernel/module.c:1103:20: warning: unused function 'print_unload_info' [-Wunused-function]
static inline void print_unload_info(struct seq_file *m, struct module *mod)
^
2 warnings generated.
vim +/exit +4478 kernel/module.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 4473
cf68fffb66d60d Sami Tolvanen 2021-04-08 4474 static void cfi_init(struct module *mod)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4475 {
cf68fffb66d60d Sami Tolvanen 2021-04-08 4476 #ifdef CONFIG_CFI_CLANG
cf68fffb66d60d Sami Tolvanen 2021-04-08 4477 initcall_t *init;
cf68fffb66d60d Sami Tolvanen 2021-04-08 @4478 exitcall_t *exit;
cf68fffb66d60d Sami Tolvanen 2021-04-08 4479
cf68fffb66d60d Sami Tolvanen 2021-04-08 4480 rcu_read_lock_sched();
cf68fffb66d60d Sami Tolvanen 2021-04-08 4481 mod->cfi_check = (cfi_check_fn)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4482 find_kallsyms_symbol_value(mod, "__cfi_check");
cf68fffb66d60d Sami Tolvanen 2021-04-08 4483 init = (initcall_t *)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4484 find_kallsyms_symbol_value(mod, "__cfi_jt_init_module");
cf68fffb66d60d Sami Tolvanen 2021-04-08 4485 exit = (exitcall_t *)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4486 find_kallsyms_symbol_value(mod, "__cfi_jt_cleanup_module");
cf68fffb66d60d Sami Tolvanen 2021-04-08 4487 rcu_read_unlock_sched();
cf68fffb66d60d Sami Tolvanen 2021-04-08 4488
cf68fffb66d60d Sami Tolvanen 2021-04-08 4489 /* Fix init/exit functions to point to the CFI jump table */
cf68fffb66d60d Sami Tolvanen 2021-04-08 4490 if (init)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4491 mod->init = *init;
0d67e332e6df72 Arnd Bergmann 2021-09-27 4492 #ifdef CONFIG_MODULE_UNLOAD
cf68fffb66d60d Sami Tolvanen 2021-04-08 4493 if (exit)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4494 mod->exit = *exit;
0d67e332e6df72 Arnd Bergmann 2021-09-27 4495 #endif
cf68fffb66d60d Sami Tolvanen 2021-04-08 4496
cf68fffb66d60d Sami Tolvanen 2021-04-08 4497 cfi_module_add(mod, module_addr_min);
cf68fffb66d60d Sami Tolvanen 2021-04-08 4498 #endif
cf68fffb66d60d Sami Tolvanen 2021-04-08 4499 }
cf68fffb66d60d Sami Tolvanen 2021-04-08 4500
:::::: The code at line 4478 was first introduced by commit
:::::: cf68fffb66d60d96209446bfc4a15291dc5a5d41 add support for Clang CFI
:::::: TO: Sami Tolvanen <samitolvanen@google.com>
:::::: CC: Kees Cook <keescook@chromium.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
^ permalink raw reply [flat|nested] 4+ messages in thread
* kernel/module.c:4478:14: warning: variable 'exit' set but not used
@ 2022-01-04 20:09 kernel test robot
0 siblings, 0 replies; 4+ messages in thread
From: kernel test robot @ 2022-01-04 20:09 UTC (permalink / raw)
Cc: kbuild-all, llvm
CC: linux-kernel@vger.kernel.org
TO: Arnd Bergmann <arnd@arndb.de>
CC: Jessica Yu <jeyu@kernel.org>
CC: Sami Tolvanen <samitolvanen@google.com>
CC: Miroslav Benes <mbenes@suse.cz>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: c9e6606c7fe92b50a02ce51dda82586ebdf99b48
commit: 0d67e332e6df72f43eaa21228daa3a79e23093f3 module: fix clang CFI with MODULE_UNLOAD=n
date: 3 months ago
config: arm64-randconfig-r022-20220101 (https://download.01.org/0day-ci/archive/20220105/202201050451.suerRBnx-lkp@intel.com/config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 7cd109b92c72855937273a6c8ab19016fbe27d33)
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 arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0d67e332e6df72f43eaa21228daa3a79e23093f3
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 0d67e332e6df72f43eaa21228daa3a79e23093f3
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm64 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All error/warnings (new ones prefixed by >>):
>> ld.lld: error: ./arch/arm64/kernel/vmlinux.lds:25: symbol not found: PMD_SIZE
>> ld.lld: error: ./arch/arm64/kernel/vmlinux.lds:25: symbol not found: PMD_SIZE
>> ld.lld: error: ./arch/arm64/kernel/vmlinux.lds:25: symbol not found: PMD_SIZE
>> ld.lld: error: ./arch/arm64/kernel/vmlinux.lds:25: symbol not found: PMD_SIZE
>> ld.lld: error: ./arch/arm64/kernel/vmlinux.lds:25: symbol not found: PMD_SIZE
>> ld.lld: error: ./arch/arm64/kernel/vmlinux.lds:25: symbol not found: PMD_SIZE
>> ld.lld: error: ./arch/arm64/kernel/vmlinux.lds:25: symbol not found: PMD_SIZE
>> ld.lld: error: ./arch/arm64/kernel/vmlinux.lds:25: symbol not found: PMD_SIZE
>> ld.lld: error: ./arch/arm64/kernel/vmlinux.lds:25: symbol not found: PMD_SIZE
>> ld.lld: error: ./arch/arm64/kernel/vmlinux.lds:25: symbol not found: PMD_SIZE
--
>> kernel/module.c:4478:14: warning: variable 'exit' set but not used [-Wunused-but-set-variable]
exitcall_t *exit;
^
1 warning generated.
vim +/exit +4478 kernel/module.c
^1da177e4c3f415 Linus Torvalds 2005-04-16 4473
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4474 static void cfi_init(struct module *mod)
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4475 {
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4476 #ifdef CONFIG_CFI_CLANG
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4477 initcall_t *init;
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 @4478 exitcall_t *exit;
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4479
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4480 rcu_read_lock_sched();
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4481 mod->cfi_check = (cfi_check_fn)
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4482 find_kallsyms_symbol_value(mod, "__cfi_check");
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4483 init = (initcall_t *)
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4484 find_kallsyms_symbol_value(mod, "__cfi_jt_init_module");
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4485 exit = (exitcall_t *)
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4486 find_kallsyms_symbol_value(mod, "__cfi_jt_cleanup_module");
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4487 rcu_read_unlock_sched();
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4488
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4489 /* Fix init/exit functions to point to the CFI jump table */
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4490 if (init)
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4491 mod->init = *init;
0d67e332e6df72f Arnd Bergmann 2021-09-27 4492 #ifdef CONFIG_MODULE_UNLOAD
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4493 if (exit)
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4494 mod->exit = *exit;
0d67e332e6df72f Arnd Bergmann 2021-09-27 4495 #endif
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4496
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4497 cfi_module_add(mod, module_addr_min);
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4498 #endif
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4499 }
cf68fffb66d60d9 Sami Tolvanen 2021-04-08 4500
:::::: The code at line 4478 was first introduced by commit
:::::: cf68fffb66d60d96209446bfc4a15291dc5a5d41 add support for Clang CFI
:::::: TO: Sami Tolvanen <samitolvanen@google.com>
:::::: CC: Kees Cook <keescook@chromium.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
^ permalink raw reply [flat|nested] 4+ messages in thread
* kernel/module.c:4478:14: warning: variable 'exit' set but not used
@ 2022-01-01 22:58 kernel test robot
0 siblings, 0 replies; 4+ messages in thread
From: kernel test robot @ 2022-01-01 22:58 UTC (permalink / raw)
To: Arnd Bergmann
Cc: llvm, kbuild-all, linux-kernel, Jessica Yu, Sami Tolvanen,
Miroslav Benes
Hi Arnd,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 278218f6778bc7d6f8b67199446c56cec7ebb841
commit: 0d67e332e6df72f43eaa21228daa3a79e23093f3 module: fix clang CFI with MODULE_UNLOAD=n
date: 3 months ago
config: arm64-randconfig-r022-20220101 (https://download.01.org/0day-ci/archive/20220102/202201020600.rl5oKvlD-lkp@intel.com/config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 7cd109b92c72855937273a6c8ab19016fbe27d33)
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 arm64 cross compiling tool for clang build
# apt-get install binutils-aarch64-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=0d67e332e6df72f43eaa21228daa3a79e23093f3
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 0d67e332e6df72f43eaa21228daa3a79e23093f3
# save the config file to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm64 SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All warnings (new ones prefixed by >>):
>> kernel/module.c:4478:14: warning: variable 'exit' set but not used [-Wunused-but-set-variable]
exitcall_t *exit;
^
1 warning generated.
vim +/exit +4478 kernel/module.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 4473
cf68fffb66d60d Sami Tolvanen 2021-04-08 4474 static void cfi_init(struct module *mod)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4475 {
cf68fffb66d60d Sami Tolvanen 2021-04-08 4476 #ifdef CONFIG_CFI_CLANG
cf68fffb66d60d Sami Tolvanen 2021-04-08 4477 initcall_t *init;
cf68fffb66d60d Sami Tolvanen 2021-04-08 @4478 exitcall_t *exit;
cf68fffb66d60d Sami Tolvanen 2021-04-08 4479
cf68fffb66d60d Sami Tolvanen 2021-04-08 4480 rcu_read_lock_sched();
cf68fffb66d60d Sami Tolvanen 2021-04-08 4481 mod->cfi_check = (cfi_check_fn)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4482 find_kallsyms_symbol_value(mod, "__cfi_check");
cf68fffb66d60d Sami Tolvanen 2021-04-08 4483 init = (initcall_t *)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4484 find_kallsyms_symbol_value(mod, "__cfi_jt_init_module");
cf68fffb66d60d Sami Tolvanen 2021-04-08 4485 exit = (exitcall_t *)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4486 find_kallsyms_symbol_value(mod, "__cfi_jt_cleanup_module");
cf68fffb66d60d Sami Tolvanen 2021-04-08 4487 rcu_read_unlock_sched();
cf68fffb66d60d Sami Tolvanen 2021-04-08 4488
cf68fffb66d60d Sami Tolvanen 2021-04-08 4489 /* Fix init/exit functions to point to the CFI jump table */
cf68fffb66d60d Sami Tolvanen 2021-04-08 4490 if (init)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4491 mod->init = *init;
0d67e332e6df72 Arnd Bergmann 2021-09-27 4492 #ifdef CONFIG_MODULE_UNLOAD
cf68fffb66d60d Sami Tolvanen 2021-04-08 4493 if (exit)
cf68fffb66d60d Sami Tolvanen 2021-04-08 4494 mod->exit = *exit;
0d67e332e6df72 Arnd Bergmann 2021-09-27 4495 #endif
cf68fffb66d60d Sami Tolvanen 2021-04-08 4496
cf68fffb66d60d Sami Tolvanen 2021-04-08 4497 cfi_module_add(mod, module_addr_min);
cf68fffb66d60d Sami Tolvanen 2021-04-08 4498 #endif
cf68fffb66d60d Sami Tolvanen 2021-04-08 4499 }
cf68fffb66d60d Sami Tolvanen 2021-04-08 4500
:::::: The code at line 4478 was first introduced by commit
:::::: cf68fffb66d60d96209446bfc4a15291dc5a5d41 add support for Clang CFI
:::::: TO: Sami Tolvanen <samitolvanen@google.com>
:::::: CC: Kees Cook <keescook@chromium.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2022-02-28 6:09 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-26 1:55 kernel/module.c:4478:14: warning: variable 'exit' set but not used kernel test robot
2022-01-01 22:58 kernel test robot
2022-01-04 20:09 kernel test robot
2022-02-28 6:09 kernel test robot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).