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>] [day] [month] [year] [list]
Message-ID: <202208050431.OUd5V0rj-lkp@intel.com>
Date:   Fri, 5 Aug 2022 04:37:11 +0800
From:   kernel test robot <lkp@...el.com>
To:     Jiri Olsa <jolsa@...nel.org>
Cc:     llvm@...ts.linux.dev, kbuild-all@...ts.01.org,
        linux-kernel@...r.kernel.org
Subject: [jolsa-perf:bpf/tracing_multi 11/18] kernel/bpf/trampoline.c:259:6:
 error: call to undeclared function 'key_in_multi_trampoline'; ISO C99 and
 later do not support implicit function declarations

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git bpf/tracing_multi
head:   3f77a2c51293ea19f1ce6a9b06b9fa394beecd13
commit: fb3e0f80af089fc89a36ad479f7adfc4dd3aa9fb [11/18] bpf: Add support to attach program to multiple trampolines
config: riscv-randconfig-r042-20220804 (https://download.01.org/0day-ci/archive/20220805/202208050431.OUd5V0rj-lkp@intel.com/config)
compiler: clang version 16.0.0 (https://github.com/llvm/llvm-project 26dd42705c2af0b8f6e5d6cdb32c9bd5ed9524eb)
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 riscv cross compiling tool for clang build
        # apt-get install binutils-riscv-linux-gnu
        # https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git/commit/?id=fb3e0f80af089fc89a36ad479f7adfc4dd3aa9fb
        git remote add jolsa-perf https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
        git fetch --no-tags jolsa-perf bpf/tracing_multi
        git checkout fb3e0f80af089fc89a36ad479f7adfc4dd3aa9fb
        # 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=riscv SHELL=/bin/bash kernel/

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

All errors (new ones prefixed by >>):

>> kernel/bpf/trampoline.c:259:6: error: call to undeclared function 'key_in_multi_trampoline'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
           if (key_in_multi_trampoline(key))
               ^
>> kernel/bpf/trampoline.c:1056:13: error: static declaration of 'key_in_multi_trampoline' follows non-static declaration
   static bool key_in_multi_trampoline(u64 key)
               ^
   kernel/bpf/trampoline.c:259:6: note: previous implicit declaration is here
           if (key_in_multi_trampoline(key))
               ^
   kernel/bpf/trampoline.c:1099:9: warning: variable 'rollback_cnt' set but not used [-Wunused-but-set-variable]
           int i, rollback_cnt = 0, err = -EINVAL;
                  ^
   kernel/bpf/trampoline.c:1100:16: warning: variable 'ip' set but not used [-Wunused-but-set-variable]
           unsigned long ip, image_new, image_old;
                         ^
   2 warnings and 2 errors generated.


vim +/key_in_multi_trampoline +259 kernel/bpf/trampoline.c

   252	
   253	static struct bpf_trampoline *bpf_trampoline_lookup(u64 key)
   254	{
   255		struct bpf_trampoline *tr = NULL;
   256		struct hlist_head *head;
   257	
   258		mutex_lock(&trampoline_mutex);
 > 259		if (key_in_multi_trampoline(key))
   260			goto out;
   261		tr = __bpf_trampoline_lookup(key);
   262		if (tr) {
   263			refcount_inc(&tr->refcnt);
   264			goto out;
   265		}
   266		tr = bpf_trampoline_alloc();
   267		if (!tr)
   268			goto out;
   269		tr->key = key;
   270		head = &trampoline_table[hash_64(key, TRAMPOLINE_HASH_BITS)];
   271		hlist_add_head(&tr->hlist, head);
   272	out:
   273		mutex_unlock(&trampoline_mutex);
   274		return tr;
   275	}
   276	

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ