Re: [PATCH 3/7] bpf: Rename BPF_XADD and prepare to encode other atomics in .imm

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Brendan,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on bpf-next/master]
[also build test ERROR on bpf/master powerpc/next linus/master v5.10-rc5 next-20201123]
[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]

url:    https://github.com/0day-ci/linux/commits/Brendan-Jackman/Atomics-for-eBPF/20201124-013549
base:   https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master
config: powerpc-randconfig-r001-20201123 (attached as .config)
compiler: clang version 12.0.0 (https://github.com/llvm/llvm-project df9ae5992889560a8f3c6760b54d5051b47c7bf5)
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 powerpc cross compiling tool for clang build
        # apt-get install binutils-powerpc-linux-gnu
        # https://github.com/0day-ci/linux/commit/d8b7356263922e2ef6596247034c6b5273d2a8b9
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Brendan-Jackman/Atomics-for-eBPF/20201124-013549
        git checkout d8b7356263922e2ef6596247034c6b5273d2a8b9
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc 

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

All errors (new ones prefixed by >>):

>> drivers/net/ethernet/netronome/nfp/bpf/verifier.c:482:7: error: implicit declaration of function 'is_mbpf_xadd' [-Werror,-Wimplicit-function-declaration]
                   if (is_mbpf_xadd(meta)) {
                       ^
   1 error generated.
--
>> drivers/net/ethernet/netronome/nfp/bpf/jit.c:3485:36: error: use of undeclared identifier 'mem_atm8'
           [BPF_STX | BPF_ATOMIC | BPF_DW] =       mem_atm8,
                                                   ^
   1 error generated.

vim +/is_mbpf_xadd +482 drivers/net/ethernet/netronome/nfp/bpf/verifier.c

dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  449  
cd7df56ed3e60d drivers/net/ethernet/netronome/nfp/nfp_bpf_verifier.c Jakub Kicinski     2016-09-21  450  static int
2ca71441f524b0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-12  451  nfp_bpf_check_ptr(struct nfp_prog *nfp_prog, struct nfp_insn_meta *meta,
638f5b90d46016 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Alexei Starovoitov 2017-10-31  452  		  struct bpf_verifier_env *env, u8 reg_no)
cd7df56ed3e60d drivers/net/ethernet/netronome/nfp/nfp_bpf_verifier.c Jakub Kicinski     2016-09-21  453  {
638f5b90d46016 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Alexei Starovoitov 2017-10-31  454  	const struct bpf_reg_state *reg = cur_regs(env) + reg_no;
ee9133a845fe8a drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  455  	int err;
70c78fc138b6d0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  456  
70c78fc138b6d0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  457  	if (reg->type != PTR_TO_CTX &&
ee9133a845fe8a drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  458  	    reg->type != PTR_TO_STACK &&
3dd43c3319cb0b drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-01-11  459  	    reg->type != PTR_TO_MAP_VALUE &&
70c78fc138b6d0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  460  	    reg->type != PTR_TO_PACKET) {
ff627e3d07a07f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Quentin Monnet     2018-01-10  461  		pr_vlog(env, "unsupported ptr type: %d\n", reg->type);
cd7df56ed3e60d drivers/net/ethernet/netronome/nfp/nfp_bpf_verifier.c Jakub Kicinski     2016-09-21  462  		return -EINVAL;
70c78fc138b6d0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  463  	}
cd7df56ed3e60d drivers/net/ethernet/netronome/nfp/nfp_bpf_verifier.c Jakub Kicinski     2016-09-21  464  
ee9133a845fe8a drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  465  	if (reg->type == PTR_TO_STACK) {
ff627e3d07a07f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Quentin Monnet     2018-01-10  466  		err = nfp_bpf_check_stack_access(nfp_prog, meta, reg, env);
ee9133a845fe8a drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  467  		if (err)
ee9133a845fe8a drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  468  			return err;
ee9133a845fe8a drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  469  	}
ee9133a845fe8a drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  470  
3dd43c3319cb0b drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-01-11  471  	if (reg->type == PTR_TO_MAP_VALUE) {
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  472  		if (is_mbpf_load(meta)) {
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  473  			err = nfp_bpf_map_mark_used(env, meta, reg,
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  474  						    NFP_MAP_USE_READ);
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  475  			if (err)
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  476  				return err;
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  477  		}
3dd43c3319cb0b drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-01-11  478  		if (is_mbpf_store(meta)) {
7dfa4d87cfc48f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-01-16  479  			pr_vlog(env, "map writes not supported\n");
3dd43c3319cb0b drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-01-11  480  			return -EOPNOTSUPP;
3dd43c3319cb0b drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-01-11  481  		}
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28 @482  		if (is_mbpf_xadd(meta)) {
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  483  			err = nfp_bpf_map_mark_used(env, meta, reg,
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  484  						    NFP_MAP_USE_ATOMIC_CNT);
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  485  			if (err)
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  486  				return err;
dcb0c27f3c989f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-03-28  487  		}
3dd43c3319cb0b drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-01-11  488  	}
3dd43c3319cb0b drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2018-01-11  489  
70c78fc138b6d0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  490  	if (meta->ptr.type != NOT_INIT && meta->ptr.type != reg->type) {
ff627e3d07a07f drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Quentin Monnet     2018-01-10  491  		pr_vlog(env, "ptr type changed for instruction %d -> %d\n",
70c78fc138b6d0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  492  			meta->ptr.type, reg->type);
2ca71441f524b0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-12  493  		return -EINVAL;
70c78fc138b6d0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  494  	}
2ca71441f524b0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-12  495  
70c78fc138b6d0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-23  496  	meta->ptr = *reg;
2ca71441f524b0 drivers/net/ethernet/netronome/nfp/bpf/verifier.c     Jakub Kicinski     2017-10-12  497  
cd7df56ed3e60d drivers/net/ethernet/netronome/nfp/nfp_bpf_verifier.c Jakub Kicinski     2016-09-21  498  	return 0;
cd7df56ed3e60d drivers/net/ethernet/netronome/nfp/nfp_bpf_verifier.c Jakub Kicinski     2016-09-21  499  }
cd7df56ed3e60d drivers/net/ethernet/netronome/nfp/nfp_bpf_verifier.c Jakub Kicinski     2016-09-21  500  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]


  Powered by Linux