[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <9AEC2C3E-D4F7-413C-A31B-557D9F56EEAC@fb.com>
Date: Mon, 15 Apr 2019 23:37:42 +0000
From: Song Liu <songliubraving@...com>
To: "andrii.nakryiko@...il.com" <andrii.nakryiko@...il.com>
CC: Networking <netdev@...r.kernel.org>,
"bpf@...r.kernel.org" <bpf@...r.kernel.org>,
Kernel Team <Kernel-team@...com>,
"David S. Miller" <davem@...emloft.net>,
Andrii Nakryiko <andriin@...com>,
Masahiro Yamada <yamada.masahiro@...ionext.com>,
Arnaldo Carvalho de Melo <acme@...hat.com>,
Daniel Borkmann <daniel@...earbox.net>,
Alexei Starovoitov <ast@...com>, Yonghong Song <yhs@...com>,
Martin Lau <kafai@...com>
Subject: Re: [PATCH bpf-next] kbuild: handle old pahole more gracefully when
generating BTF
> On Apr 15, 2019, at 2:58 PM, andrii.nakryiko@...il.com wrote:
>
> From: Andrii Nakryiko <andriin@...com>
>
> When CONFIG_DEBUG_INFO_BTF is enabled but available version of pahole is too
> old to support BTF generation, build script is supposed to emit warning and
> proceed with the build. Due to using exit instead of return from BASH function,
> existing handling code prematurely exits exit code 0, not completing some of
> the build steps. This patch fixes issue by correctly returning just from
> gen_btf() function only.
>
> Fixes: e83b9f55448a ("kbuild: add ability to generate BTF type info for vmlinux")
> Cc: Masahiro Yamada <yamada.masahiro@...ionext.com>
> Cc: Arnaldo Carvalho de Melo <acme@...hat.com>
> Cc: Daniel Borkmann <daniel@...earbox.net>
> Cc: Alexei Starovoitov <ast@...com>
> Cc: Yonghong Song <yhs@...com>
> Cc: Martin KaFai Lau <kafai@...com>
> Signed-off-by: Andrii Nakryiko <andriin@...com>
Acked-by: Song Liu <songliubraving@...com>
> ---
> scripts/link-vmlinux.sh | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/scripts/link-vmlinux.sh b/scripts/link-vmlinux.sh
> index dd2b31ccca6a..6a148d0d51bf 100755
> --- a/scripts/link-vmlinux.sh
> +++ b/scripts/link-vmlinux.sh
> @@ -99,7 +99,7 @@ gen_btf()
> pahole_ver=$(${PAHOLE} --version | sed -E 's/v([0-9]+)\.([0-9]+)/\1\2/')
> if [ "${pahole_ver}" -lt "113" ]; then
> info "BTF" "${1}: pahole version $(${PAHOLE} --version) is too old, need at least v1.13"
> - exit 0
> + return 0
> fi
>
> info "BTF" ${1}
> --
> 2.17.1
>
Powered by blists - more mailing lists