sched: delete some api is not used
Subsystems (3)
PATCH 1/1 sched: delete some api is not used
From: lingfuyi <[email protected]>
fix compile errors like this:net/sched/cls_api.c:141:13: error: ‘tcf_exts_miss_cookie_base_destroy’ defined but not used [-Werror=unused-function]
--- net/sched/cls_api.c | 3 --- 1 file changed, 3 deletions(-)
net/sched/cls_api.c +0 -3
@@ -138,9 +138,6 @@ tcf_exts_miss_cookie_base_alloc(struct tcf_exts *exts, struct tcf_proto *tp, return 0; } -static void tcf_exts_miss_cookie_base_destroy (struct tcf_exts *exts) -{ -}#endif /* IS_ENABLED(CONFIG_NET_TC_SKB_EXT) */ static u64 tcf_exts_miss_cookie_get (u32 miss_cookie_base,int act_index)
Signature · 1 line
2.25.1
kernel test robot
build botThank you for the patch! Yet something to improve:
Hi lingfuyi,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on horms-ipvs/master]
[also build test ERROR on linus/master next-20230228] [cannot apply to v6.2]
[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/lingfuyi/sched-delete-some-api-is-not-used/20230228-124804 base: https://git.kernel.org/pub/scm/linux/kernel/git/horms/ipvs.git master patch link: https://lore.kernel.org/r/20230228031241.1675263-1-lingfuyi%40126.com patch subject: [PATCH] sched: delete some api is not used config: i386-randconfig-a013-20230227 (https://download.01.org/0day-ci/archive/20230228/[email protected]/config) compiler: gcc-11 (Debian 11.3.0-8) 11.3.0
reproduce (this is a W=1 build):
# https://github.com/intel-lab-lkp/linux/commit/6d9fd0340845396f9866b8a8c53ad65066de39ac
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review lingfuyi/sched-delete-some-api-is-not-used/20230228-124804 git checkout 6d9fd0340845396f9866b8a8c53ad65066de39ac
# save the config file
mkdir build_dir && cp config build_dir/.config
make W=1 O=build_dir ARCH=i386 olddefconfig
make W=1 O=build_dir ARCH=i386 SHELL=/bin/bash
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <[email protected]>
| Link: https://lore.kernel.org/oe-kbuild-all/[email protected]/
All errors (new ones prefixed by >>):
net/sched/cls_api.c: In function 'tcf_exts_destroy':
>> net/sched/cls_api.c:3242:9: error: implicit declaration of function 'tcf_exts_miss_cookie_base_destroy'; did you mean 'tcf_exts_miss_cookie_base_alloc'? [-Werror=implicit-function-declaration]
3242 | tcf_exts_miss_cookie_base_destroy(exts);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| tcf_exts_miss_cookie_base_alloccc1: some warnings being treated as errors
vim +3242 net/sched/cls_api.c
80cd22c35c9001 Paul Blakey 2023-02-18 3238
18d0264f630e20 WANG Cong 2014-09-25 3239 void tcf_exts_destroy(struct tcf_exts *exts)
^1da177e4c3f41 Linus Torvalds 2005-04-16 3240 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 3241 #ifdef CONFIG_NET_CLS_ACT
80cd22c35c9001 Paul Blakey 2023-02-18 @3242 tcf_exts_miss_cookie_base_destroy(exts);
80cd22c35c9001 Paul Blakey 2023-02-18 3243
3d66b89c30f922 Eric Dumazet 2019-09-18 3244 if (exts->actions) {
90b73b77d08ec3 Vlad Buslov 2018-07-05 3245 tcf_action_destroy(exts->actions, TCA_ACT_UNBIND);
22dc13c837c332 WANG Cong 2016-08-13 3246 kfree(exts->actions);
3d66b89c30f922 Eric Dumazet 2019-09-18 3247 }
22dc13c837c332 WANG Cong 2016-08-13 3248 exts->nr_actions = 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 3249 #endif
^1da177e4c3f41 Linus Torvalds 2005-04-16 3250 }aa767bfea48289 Stephen Hemminger 2008-01-21 3251 EXPORT_SYMBOL(tcf_exts_destroy);
^1da177e4c3f41 Linus Torvalds 2005-04-16 3252
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests
kernel test robot
build botThank you for the patch! Yet something to improve:
Hi lingfuyi,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on horms-ipvs/master]
[also build test ERROR on linus/master next-20230228] [cannot apply to v6.2]
[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/lingfuyi/sched-delete-some-api-is-not-used/20230228-124804 base: https://git.kernel.org/pub/scm/linux/kernel/git/horms/ipvs.git master patch link: https://lore.kernel.org/r/20230228031241.1675263-1-lingfuyi%40126.com patch subject: [PATCH] sched: delete some api is not used config: x86_64-randconfig-a001-20230227 (https://download.01.org/0day-ci/archive/20230228/[email protected]/config) compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project f28c006a5895fc0e329fe15fead81e37457cb1d1)
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
# https://github.com/intel-lab-lkp/linux/commit/6d9fd0340845396f9866b8a8c53ad65066de39ac
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review lingfuyi/sched-delete-some-api-is-not-used/20230228-124804 git checkout 6d9fd0340845396f9866b8a8c53ad65066de39ac
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 olddefconfig COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash net/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <[email protected]>
| Link: https://lore.kernel.org/oe-kbuild-all/[email protected]/
All errors (new ones prefixed by >>):
>> net/sched/cls_api.c:3242:2: error: implicit declaration of function 'tcf_exts_miss_cookie_base_destroy' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
tcf_exts_miss_cookie_base_destroy(exts);
^ net/sched/cls_api.c:3242:2: note: did you mean 'tcf_exts_miss_cookie_base_alloc'? net/sched/cls_api.c:135:1: note: 'tcf_exts_miss_cookie_base_alloc' declared here tcf_exts_miss_cookie_base_alloc(struct tcf_exts *exts, struct tcf_proto *tp, ^
1 error generated.
vim +/tcf_exts_miss_cookie_base_destroy +3242 net/sched/cls_api.c
80cd22c35c9001 Paul Blakey 2023-02-18 3238
18d0264f630e20 WANG Cong 2014-09-25 3239 void tcf_exts_destroy(struct tcf_exts *exts)
^1da177e4c3f41 Linus Torvalds 2005-04-16 3240 {
^1da177e4c3f41 Linus Torvalds 2005-04-16 3241 #ifdef CONFIG_NET_CLS_ACT
80cd22c35c9001 Paul Blakey 2023-02-18 @3242 tcf_exts_miss_cookie_base_destroy(exts);
80cd22c35c9001 Paul Blakey 2023-02-18 3243
3d66b89c30f922 Eric Dumazet 2019-09-18 3244 if (exts->actions) {
90b73b77d08ec3 Vlad Buslov 2018-07-05 3245 tcf_action_destroy(exts->actions, TCA_ACT_UNBIND);
22dc13c837c332 WANG Cong 2016-08-13 3246 kfree(exts->actions);
3d66b89c30f922 Eric Dumazet 2019-09-18 3247 }
22dc13c837c332 WANG Cong 2016-08-13 3248 exts->nr_actions = 0;
^1da177e4c3f41 Linus Torvalds 2005-04-16 3249 #endif
^1da177e4c3f41 Linus Torvalds 2005-04-16 3250 }aa767bfea48289 Stephen Hemminger 2008-01-21 3251 EXPORT_SYMBOL(tcf_exts_destroy);
^1da177e4c3f41 Linus Torvalds 2005-04-16 3252
Signature · 2 lines
0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests
Paolo Abeni
maintainerQuoted 8 lines · lingfuyi
From: lingfuyi <[email protected]>
fix compile errors like this:
net/sched/cls_api.c:141:13: error: ‘tcf_exts_miss_cookie_base_destroy’ defined but not used [-Werror=unused-function]Reported-by k2ci <[email protected]>Signed-off-by lingfuyi <[email protected]>
This has been already addressed by:
commit 37e1f3acc339b28493eb3dad571c3f01b6af86f6
Author: Nathan Chancellor <[email protected]> Date: Fri Feb 24 11:18:49 2023 -0700
net/sched: cls_api: Move call to tcf_exts_miss_cookie_base_destroy()
Thanks,
Paolo