[jolsa-perf:bpf/tracing_multi 12/18] include/linux/trace_events.h:797:5: error: no previous prototype for 'bpf_tracing_multi_attach'

From: kernel test robot
Date: Thu Aug 04 2022 - 15:06:38 EST


tree: https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git bpf/tracing_multi
head: 3f77a2c51293ea19f1ce6a9b06b9fa394beecd13
commit: e005380dc118dbc67a921f1797c50541f4c3f1e5 [12/18] bpf: Add support to create tracing multi link
config: i386-defconfig (https://download.01.org/0day-ci/archive/20220805/202208050220.aexUPtTV-lkp@xxxxxxxxx/config)
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce (this is a W=1 build):
# https://git.kernel.org/pub/scm/linux/kernel/git/jolsa/perf.git/commit/?id=e005380dc118dbc67a921f1797c50541f4c3f1e5
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 e005380dc118dbc67a921f1797c50541f4c3f1e5
# save the config file
mkdir build_dir && cp config build_dir/.config
make W=1 O=build_dir ARCH=i386 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 >>):

In file included from include/trace/trace_events.h:21,
from include/trace/define_trace.h:102,
from drivers/gpu/drm/i915/i915_trace.h:770,
from drivers/gpu/drm/i915/i915_trace_points.c:13:
>> include/linux/trace_events.h:797:5: error: no previous prototype for 'bpf_tracing_multi_attach' [-Werror=missing-prototypes]
797 | int bpf_tracing_multi_attach(struct bpf_prog *prog, const union bpf_attr *attr)
| ^~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors


vim +/bpf_tracing_multi_attach +797 include/linux/trace_events.h

764
765 static inline int
766 perf_event_query_prog_array(struct perf_event *event, void __user *info)
767 {
768 return -EOPNOTSUPP;
769 }
770 static inline int bpf_probe_register(struct bpf_raw_event_map *btp, struct bpf_prog *p)
771 {
772 return -EOPNOTSUPP;
773 }
774 static inline int bpf_probe_unregister(struct bpf_raw_event_map *btp, struct bpf_prog *p)
775 {
776 return -EOPNOTSUPP;
777 }
778 static inline struct bpf_raw_event_map *bpf_get_raw_tracepoint(const char *name)
779 {
780 return NULL;
781 }
782 static inline void bpf_put_raw_tracepoint(struct bpf_raw_event_map *btp)
783 {
784 }
785 static inline int bpf_get_perf_event_info(const struct perf_event *event,
786 u32 *prog_id, u32 *fd_type,
787 const char **buf, u64 *probe_offset,
788 u64 *probe_addr)
789 {
790 return -EOPNOTSUPP;
791 }
792 static inline int
793 bpf_kprobe_multi_link_attach(const union bpf_attr *attr, struct bpf_prog *prog)
794 {
795 return -EOPNOTSUPP;
796 }
> 797 int bpf_tracing_multi_attach(struct bpf_prog *prog, const union bpf_attr *attr)
798 {
799 return -EOPNOTSUPP;
800 }
801 #endif
802

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