Re: [PATCH net-next] samples/bpf: Fix compilation issue in redirect dummy program
From: Tariq Toukan <hidden>
Date: 2017-08-31 12:30:30
On 31/08/2017 2:43 PM, Daniel Borkmann wrote:
On 08/31/2017 01:27 PM, Jesper Dangaard Brouer wrote:quoted
On Thu, 31 Aug 2017 14:16:39 +0300 Tariq Toukan [off-list ref] wrote:quoted
Fix compilation error below: $ make samples/bpf/ LLVM ERROR: 'xdp_redirect_dummy' label emitted multiple times to assembly file make[1]: *** [samples/bpf/xdp_redirect_kern.o] Error 1 make: *** [samples/bpf/] Error 2 Fixes: 306da4e685b4 ("samples/bpf: xdp_redirect load XDP dummy prog on TX device") Signed-off-by: Tariq Toukan <redacted> ---Acked-by: Jesper Dangaard Brouer <redacted>Acked-by: Daniel Borkmann <daniel@iogearbox.net>quoted
What LLVM/clang version do you use?
clang version 3.8.0 (tags/RELEASE_380/final)
quoted
I don't see this compile error, and I have: $ clang --version clang version 3.9.1 (tags/RELEAI'm seeing the error as well with a fairly recent LLVM from git tree (6.0.0git-2d810c2). Looks like the llvm error is triggered when section name and the function name for XDP prog is the same. Changing either the function or the section name right above resolves the issue. If such error didn't trigger on older versions, people could be using such naming scheme as done here, so seems to me like a regression on LLVM side we might need to look at ...
Agreed.
In any case, patch here is fine, thanks!
Thank you.