[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202108271643.vreS3DSl-lkp@intel.com>
Date: Fri, 27 Aug 2021 16:53:50 +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/batch 19/27] include/linux/bpf.h:707:20: error:
field has incomplete type 'struct ftrace_ops'
tree: https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git bpf/batch
head: b81b17307e02f8e6d4abf87e7ec2d7e5aea1e0b5
commit: 847fb4eb93cf46ad827ba84404d2c9d6998ea67f [19/27] bpf: Attach multi trampoline with ftrace_ops
config: riscv-buildonly-randconfig-r006-20210826 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 1076082a0d97bd5c16a25ee7cf3dbb6ee4b5a9fe)
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-riscv64-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git/commit/?id=847fb4eb93cf46ad827ba84404d2c9d6998ea67f
git remote add jolsa-perf https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git
git fetch --no-tags jolsa-perf bpf/batch
git checkout 847fb4eb93cf46ad827ba84404d2c9d6998ea67f
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross O=build_dir ARCH=riscv SHELL=/bin/bash drivers/net/ethernet/hisilicon/hns/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>
All errors (new ones prefixed by >>):
In file included from drivers/net/ethernet/hisilicon/hns/hns_ethtool.c:6:
In file included from include/linux/etherdevice.h:21:
In file included from include/linux/netdevice.h:41:
In file included from include/net/netprio_cgroup.h:11:
In file included from include/linux/cgroup.h:28:
In file included from include/linux/cgroup-defs.h:22:
In file included from include/linux/bpf-cgroup.h:5:
In file included from include/linux/bpf.h:26:
include/linux/ftrace.h:353:41: warning: declaration of 'struct ftrace_ops' will not be visible outside of this function [-Wvisibility]
int register_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:353:5: warning: no previous prototype for function 'register_ftrace_direct_multi' [-Wmissing-prototypes]
int register_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:353:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int register_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
static
include/linux/ftrace.h:357:43: warning: declaration of 'struct ftrace_ops' will not be visible outside of this function [-Wvisibility]
int unregister_ftrace_direct_multi(struct ftrace_ops *ops)
^
include/linux/ftrace.h:357:5: warning: no previous prototype for function 'unregister_ftrace_direct_multi' [-Wmissing-prototypes]
int unregister_ftrace_direct_multi(struct ftrace_ops *ops)
^
include/linux/ftrace.h:357:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int unregister_ftrace_direct_multi(struct ftrace_ops *ops)
^
static
include/linux/ftrace.h:361:39: warning: declaration of 'struct ftrace_ops' will not be visible outside of this function [-Wvisibility]
int modify_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:361:5: warning: no previous prototype for function 'modify_ftrace_direct_multi' [-Wmissing-prototypes]
int modify_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:361:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int modify_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
static
In file included from drivers/net/ethernet/hisilicon/hns/hns_ethtool.c:6:
In file included from include/linux/etherdevice.h:21:
In file included from include/linux/netdevice.h:41:
In file included from include/net/netprio_cgroup.h:11:
In file included from include/linux/cgroup.h:28:
In file included from include/linux/cgroup-defs.h:22:
In file included from include/linux/bpf-cgroup.h:5:
>> include/linux/bpf.h:707:20: error: field has incomplete type 'struct ftrace_ops'
struct ftrace_ops ops;
^
include/linux/bpf.h:707:9: note: forward declaration of 'struct ftrace_ops'
struct ftrace_ops ops;
^
6 warnings and 1 error generated.
--
In file included from drivers/net/ethernet/hisilicon/hns/hns_enet.c:8:
In file included from include/linux/etherdevice.h:21:
In file included from include/linux/netdevice.h:41:
In file included from include/net/netprio_cgroup.h:11:
In file included from include/linux/cgroup.h:28:
In file included from include/linux/cgroup-defs.h:22:
In file included from include/linux/bpf-cgroup.h:5:
In file included from include/linux/bpf.h:26:
include/linux/ftrace.h:353:41: warning: declaration of 'struct ftrace_ops' will not be visible outside of this function [-Wvisibility]
int register_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:353:5: warning: no previous prototype for function 'register_ftrace_direct_multi' [-Wmissing-prototypes]
int register_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:353:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int register_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
static
include/linux/ftrace.h:357:43: warning: declaration of 'struct ftrace_ops' will not be visible outside of this function [-Wvisibility]
int unregister_ftrace_direct_multi(struct ftrace_ops *ops)
^
include/linux/ftrace.h:357:5: warning: no previous prototype for function 'unregister_ftrace_direct_multi' [-Wmissing-prototypes]
int unregister_ftrace_direct_multi(struct ftrace_ops *ops)
^
include/linux/ftrace.h:357:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int unregister_ftrace_direct_multi(struct ftrace_ops *ops)
^
static
include/linux/ftrace.h:361:39: warning: declaration of 'struct ftrace_ops' will not be visible outside of this function [-Wvisibility]
int modify_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:361:5: warning: no previous prototype for function 'modify_ftrace_direct_multi' [-Wmissing-prototypes]
int modify_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:361:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int modify_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
static
In file included from drivers/net/ethernet/hisilicon/hns/hns_enet.c:8:
In file included from include/linux/etherdevice.h:21:
In file included from include/linux/netdevice.h:41:
In file included from include/net/netprio_cgroup.h:11:
In file included from include/linux/cgroup.h:28:
In file included from include/linux/cgroup-defs.h:22:
In file included from include/linux/bpf-cgroup.h:5:
>> include/linux/bpf.h:707:20: error: field has incomplete type 'struct ftrace_ops'
struct ftrace_ops ops;
^
include/linux/bpf.h:707:9: note: forward declaration of 'struct ftrace_ops'
struct ftrace_ops ops;
^
drivers/net/ethernet/hisilicon/hns/hns_enet.c:2355:38: warning: shift count >= width of type [-Wshift-count-overflow]
if (!dma_set_mask_and_coherent(dev, DMA_BIT_MASK(64)))
^~~~~~~~~~~~~~~~
include/linux/dma-mapping.h:76:54: note: expanded from macro 'DMA_BIT_MASK'
#define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1))
^ ~~~
7 warnings and 1 error generated.
--
In file included from drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c:12:
In file included from include/linux/netdevice.h:41:
In file included from include/net/netprio_cgroup.h:11:
In file included from include/linux/cgroup.h:28:
In file included from include/linux/cgroup-defs.h:22:
In file included from include/linux/bpf-cgroup.h:5:
In file included from include/linux/bpf.h:26:
include/linux/ftrace.h:353:41: warning: declaration of 'struct ftrace_ops' will not be visible outside of this function [-Wvisibility]
int register_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:353:5: warning: no previous prototype for function 'register_ftrace_direct_multi' [-Wmissing-prototypes]
int register_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:353:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int register_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
static
include/linux/ftrace.h:357:43: warning: declaration of 'struct ftrace_ops' will not be visible outside of this function [-Wvisibility]
int unregister_ftrace_direct_multi(struct ftrace_ops *ops)
^
include/linux/ftrace.h:357:5: warning: no previous prototype for function 'unregister_ftrace_direct_multi' [-Wmissing-prototypes]
int unregister_ftrace_direct_multi(struct ftrace_ops *ops)
^
include/linux/ftrace.h:357:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int unregister_ftrace_direct_multi(struct ftrace_ops *ops)
^
static
include/linux/ftrace.h:361:39: warning: declaration of 'struct ftrace_ops' will not be visible outside of this function [-Wvisibility]
int modify_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:361:5: warning: no previous prototype for function 'modify_ftrace_direct_multi' [-Wmissing-prototypes]
int modify_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
include/linux/ftrace.h:361:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
int modify_ftrace_direct_multi(struct ftrace_ops *ops, unsigned long addr)
^
static
In file included from drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c:12:
In file included from include/linux/netdevice.h:41:
In file included from include/net/netprio_cgroup.h:11:
In file included from include/linux/cgroup.h:28:
In file included from include/linux/cgroup-defs.h:22:
In file included from include/linux/bpf-cgroup.h:5:
>> include/linux/bpf.h:707:20: error: field has incomplete type 'struct ftrace_ops'
struct ftrace_ops ops;
^
include/linux/bpf.h:707:9: note: forward declaration of 'struct ftrace_ops'
struct ftrace_ops ops;
^
drivers/net/ethernet/hisilicon/hns/hns_dsaf_main.c:200:48: warning: shift count >= width of type [-Wshift-count-overflow]
if (!dma_set_mask_and_coherent(dsaf_dev->dev, DMA_BIT_MASK(64ULL)))
^~~~~~~~~~~~~~~~~~~
include/linux/dma-mapping.h:76:54: note: expanded from macro 'DMA_BIT_MASK'
#define DMA_BIT_MASK(n) (((n) == 64) ? ~0ULL : ((1ULL<<(n))-1))
^ ~~~
7 warnings and 1 error generated.
vim +707 include/linux/bpf.h
701
702 struct bpf_trampoline_multi {
703 struct bpf_trampoline main;
704 struct list_head list;
705 u32 *ids;
706 u32 ids_cnt;
> 707 struct ftrace_ops ops;
708 int tr_cnt;
709 struct bpf_trampoline *tr[];
710 };
711
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
Download attachment ".config.gz" of type "application/gzip" (35762 bytes)
Powered by blists - more mailing lists