Re: [PATCH bpf-next 2/3] bpf: Add support for writing to nf_conn:mark

From: kernel test robot
Date: Tue Aug 16 2022 - 02:38:16 EST


Hi Daniel,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on bpf-next/master]

url: https://github.com/intel-lab-lkp/linux/commits/Daniel-Xu/Support-direct-writes-to-nf_conn-mark/20220816-060429
base: https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master
config: um-x86_64_defconfig (https://download.01.org/0day-ci/archive/20220816/202208160931.5FG8tZ8G-lkp@xxxxxxxxx/config)
compiler: gcc-11 (Debian 11.3.0-5) 11.3.0
reproduce (this is a W=1 build):
# https://github.com/intel-lab-lkp/linux/commit/c7b21d163eb9c61514dd86baf4281deb4d4387bb
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Daniel-Xu/Support-direct-writes-to-nf_conn-mark/20220816-060429
git checkout c7b21d163eb9c61514dd86baf4281deb4d4387bb
# save the config file
mkdir build_dir && cp config build_dir/.config
make W=1 O=build_dir ARCH=um SUBARCH=x86_64 SHELL=/bin/bash

If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@xxxxxxxxx>

All errors (new ones prefixed by >>):

net/core/filter.c: In function 'tc_cls_act_btf_struct_access':
>> net/core/filter.c:8723:24: error: implicit declaration of function 'btf_struct_access' [-Werror=implicit-function-declaration]
8723 | return btf_struct_access(log, btf, t, off, size, atype, next_btf_id,
| ^~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors


vim +/btf_struct_access +8723 net/core/filter.c

8714
8715 static int tc_cls_act_btf_struct_access(struct bpf_verifier_log *log,
8716 const struct btf *btf,
8717 const struct btf_type *t, int off,
8718 int size, enum bpf_access_type atype,
8719 u32 *next_btf_id,
8720 enum bpf_type_flag *flag)
8721 {
8722 if (atype == BPF_READ)
> 8723 return btf_struct_access(log, btf, t, off, size, atype, next_btf_id,
8724 flag);
8725
8726 return nf_conntrack_btf_struct_access(log, btf, t, off, size, atype,
8727 next_btf_id, flag);
8728 }
8729

--
0-DAY CI Kernel Test Service
https://01.org/lkp