summaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/firmware
diff options
context:
space:
mode:
authorStanislav Fomichev <sdf@google.com>2018-12-12 04:20:52 +0100
committerAlexei Starovoitov <ast@kernel.org>2018-12-13 00:33:07 +0100
commita0517a0f7ef23550b4484c37e2b9c2d32abebf64 (patch)
tree9d95b1beafb6d6a7de8c310cfe23892385c358e9 /tools/testing/selftests/firmware
parentbpf: arm64: Enable arm64 jit to provide bpf_line_info (diff)
downloadlinux-a0517a0f7ef23550b4484c37e2b9c2d32abebf64.tar.xz
linux-a0517a0f7ef23550b4484c37e2b9c2d32abebf64.zip
selftests/bpf: use __bpf_constant_htons in test_prog.c
For some reason, my older GCC (< 4.8) isn't smart enough to optimize the !__builtin_constant_p() branch in bpf_htons, I see: error: implicit declaration of function '__builtin_bswap16' Let's use __bpf_constant_htons as suggested by Daniel Borkmann. I tried to use simple htons, but it produces the following: test_progs.c:54:17: error: braced-group within expression allowed only inside a function .eth.h_proto = htons(ETH_P_IP), Signed-off-by: Stanislav Fomichev <sdf@google.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net> Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Diffstat (limited to 'tools/testing/selftests/firmware')
0 files changed, 0 insertions, 0 deletions