lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Thu, 2 Nov 2023 18:23:38 +0800
From: kernel test robot <lkp@...el.com>
To: thinker.li@...il.com, bpf@...r.kernel.org, ast@...nel.org,
	martin.lau@...ux.dev, song@...nel.org, kernel-team@...a.com,
	andrii@...nel.org, drosen@...gle.com
Cc: oe-kbuild-all@...ts.linux.dev, sinquersw@...il.com, kuifeng@...a.com,
	Kui-Feng Lee <thinker.li@...il.com>, netdev@...r.kernel.org
Subject: Re: [PATCH bpf-next v9 09/12] bpf, net: switch to dynamic
 registration

Hi,

kernel test robot noticed the following build errors:

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

url:    https://github.com/intel-lab-lkp/linux/commits/thinker-li-gmail-com/bpf-refactory-struct_ops-type-initialization-to-a-function/20231102-044820
base:   https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf-next.git master
patch link:    https://lore.kernel.org/r/20231101204519.677870-10-thinker.li%40gmail.com
patch subject: [PATCH bpf-next v9 09/12] bpf, net: switch to dynamic registration
config: x86_64-randconfig-013-20231102 (https://download.01.org/0day-ci/archive/20231102/202311021810.n3qVl5OS-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-12) 11.3.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20231102/202311021810.n3qVl5OS-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202311021810.n3qVl5OS-lkp@intel.com/

All errors (new ones prefixed by >>):

   ld: kernel/bpf/btf.o: in function `btf_add_struct_ops':
>> kernel/bpf/btf.c:8662: undefined reference to `bpf_struct_ops_desc_init'


vim +8662 kernel/bpf/btf.c

  8619	
  8620	static int
  8621	btf_add_struct_ops(struct btf *btf, struct bpf_struct_ops *st_ops,
  8622			   struct bpf_verifier_log *log)
  8623	{
  8624		struct btf_struct_ops_tab *tab, *new_tab;
  8625		int i, err;
  8626	
  8627		if (!btf)
  8628			return -ENOENT;
  8629	
  8630		/* Assume this function is called for a module when the module is
  8631		 * loading.
  8632		 */
  8633	
  8634		tab = btf->struct_ops_tab;
  8635		if (!tab) {
  8636			tab = kzalloc(offsetof(struct btf_struct_ops_tab, ops[4]),
  8637				      GFP_KERNEL);
  8638			if (!tab)
  8639				return -ENOMEM;
  8640			tab->capacity = 4;
  8641			btf->struct_ops_tab = tab;
  8642		}
  8643	
  8644		for (i = 0; i < tab->cnt; i++)
  8645			if (tab->ops[i].st_ops == st_ops)
  8646				return -EEXIST;
  8647	
  8648		if (tab->cnt == tab->capacity) {
  8649			new_tab = krealloc(tab,
  8650					   offsetof(struct btf_struct_ops_tab,
  8651						    ops[tab->capacity * 2]),
  8652					   GFP_KERNEL);
  8653			if (!new_tab)
  8654				return -ENOMEM;
  8655			tab = new_tab;
  8656			tab->capacity *= 2;
  8657			btf->struct_ops_tab = tab;
  8658		}
  8659	
  8660		tab->ops[btf->struct_ops_tab->cnt].st_ops = st_ops;
  8661	
> 8662		err = bpf_struct_ops_desc_init(&tab->ops[btf->struct_ops_tab->cnt], btf, log);
  8663		if (err)
  8664			return err;
  8665	
  8666		btf->struct_ops_tab->cnt++;
  8667	
  8668		return 0;
  8669	}
  8670	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ