Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1736157

Re: [PATCH v4 3/4] samples/bpf: Fix pt_regs issues when cross-compiling

From Daniel Borkmann <daniel@iogearbox.net>
Newsgroups linux.kernel
Subject Re: [PATCH v4 3/4] samples/bpf: Fix pt_regs issues when cross-compiling
Date 2017-09-20 23:30 +0200
Message-ID <urUJb-8w7-1@gated-at.bofh.it> (permalink)
References <urPTb-5ov-3@gated-at.bofh.it> <urPTc-5ov-21@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On 09/20/2017 06:11 PM, Joel Fernandes wrote:
> BPF samples fail to build when cross-compiling for ARM64 because of incorrect
> pt_regs param selection. This is because clang defines __x86_64__ and
> bpf_headers thinks we're building for x86. Since clang is building for the BPF
> target, it shouldn't make assumptions about what target the BPF program is
> going to run on. To fix this, lets pass ARCH so the header knows which target
> the BPF program is being compiled for and can use the correct pt_regs code.
>
> Acked-by: Alexei Starovoitov <ast@kernel.org>
> Signed-off-by: Joel Fernandes <joelaf@google.com>

Acked-by: Daniel Borkmann <daniel@iogearbox.net>

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v4 1/4] samples/bpf: Use getppid instead of getpgrp for array map stress Joel Fernandes <joelaf@google.com> - 2017-09-20 18:20 +0200
  [PATCH v4 3/4] samples/bpf: Fix pt_regs issues when cross-compiling Joel Fernandes <joelaf@google.com> - 2017-09-20 18:20 +0200
    Re: [PATCH v4 3/4] samples/bpf: Fix pt_regs issues when cross-compiling Daniel Borkmann <daniel@iogearbox.net> - 2017-09-20 23:30 +0200
  Re: [PATCH v4 1/4] samples/bpf: Use getppid instead of getpgrp for  array map stress Daniel Borkmann <daniel@iogearbox.net> - 2017-09-20 23:30 +0200

csiph-web