[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Mon, 6 Jul 2020 17:38:54 -0700
From: Andrii Nakryiko <andrii.nakryiko@...il.com>
To: Jiri Olsa <jolsa@...nel.org>
Cc: Alexei Starovoitov <ast@...nel.org>,
Daniel Borkmann <daniel@...earbox.net>,
Andrii Nakryiko <andriin@...com>,
Networking <netdev@...r.kernel.org>, bpf <bpf@...r.kernel.org>,
Song Liu <songliubraving@...com>, Yonghong Song <yhs@...com>,
Martin KaFai Lau <kafai@...com>,
David Miller <davem@...hat.com>,
John Fastabend <john.fastabend@...il.com>,
Wenbo Zhang <ethercflow@...il.com>,
KP Singh <kpsingh@...omium.org>,
Brendan Gregg <bgregg@...flix.com>,
Florent Revest <revest@...omium.org>,
Al Viro <viro@...iv.linux.org.uk>
Subject: Re: [PATCH v5 bpf-next 4/9] bpf: Resolve BTF IDs in vmlinux image
On Fri, Jul 3, 2020 at 2:52 AM Jiri Olsa <jolsa@...nel.org> wrote:
>
> Using BTF_ID_LIST macro to define lists for several helpers
> using BTF arguments.
>
> And running resolve_btfids on vmlinux elf object during linking,
> so the .BTF_ids section gets the IDs resolved.
>
> Acked-by: Andrii Nakryiko <andriin@...com>
> Signed-off-by: Jiri Olsa <jolsa@...nel.org>
> ---
> Makefile | 3 ++-
> kernel/trace/bpf_trace.c | 9 +++++++--
> net/core/filter.c | 9 +++++++--
> scripts/link-vmlinux.sh | 6 ++++++
> 4 files changed, 22 insertions(+), 5 deletions(-)
>
> diff --git a/Makefile b/Makefile
> index 8db4fd8097e0..def58d4f9ed7 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -448,6 +448,7 @@ OBJSIZE = $(CROSS_COMPILE)size
> STRIP = $(CROSS_COMPILE)strip
> endif
> PAHOLE = pahole
> +RESOLVE_BTFIDS = $(srctree)/tools/bpf/resolve_btfids/resolve_btfids
Oh, this is probably wrong and why out-of-tree build fails. Why don't
you follow how this is done for objtool?
> LEX = flex
> YACC = bison
> AWK = awk
> @@ -510,7 +511,7 @@ GCC_PLUGINS_CFLAGS :=
> CLANG_FLAGS :=
>
> export ARCH SRCARCH CONFIG_SHELL BASH HOSTCC KBUILD_HOSTCFLAGS CROSS_COMPILE LD CC
> -export CPP AR NM STRIP OBJCOPY OBJDUMP OBJSIZE READELF PAHOLE LEX YACC AWK INSTALLKERNEL
> +export CPP AR NM STRIP OBJCOPY OBJDUMP OBJSIZE READELF PAHOLE RESOLVE_BTFIDS LEX YACC AWK INSTALLKERNEL
> export PERL PYTHON PYTHON3 CHECK CHECKFLAGS MAKE UTS_MACHINE HOSTCXX
> export KGZIP KBZIP2 KLZOP LZMA LZ4 XZ
> export KBUILD_HOSTCXXFLAGS KBUILD_HOSTLDFLAGS KBUILD_HOSTLDLIBS LDFLAGS_MODULE
[...]
Powered by blists - more mailing lists