linux-stable/tools/bpf
John Fastabend c034a177d3 bpf: bpftool, add flag to allow non-compat map definitions
Multiple map definition structures exist and user may have non-zero
fields in their definition that are not recognized by bpftool and
libbpf. The normal behavior is to then fail loading the map. Although
this is a good default behavior users may still want to load the map
for debugging or other reasons. This patch adds a --mapcompat flag
that can be used to override the default behavior and allow loading
the map even when it has additional non-zero fields.

For now the only user is 'bpftool prog' we can switch over other
subcommands as needed. The library exposes an API that consumes
a flags field now but I kept the original API around also in case
users of the API don't want to expose this. The flags field is an
int in case we need more control over how the API call handles
errors/features/etc in the future.

Signed-off-by: John Fastabend <john.fastabend@gmail.com>
Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
2018-10-15 16:13:14 -07:00
..
bpftool bpf: bpftool, add flag to allow non-compat map definitions 2018-10-15 16:13:14 -07:00
.gitignore tools/bpftool: ignore build products 2018-07-26 02:50:26 +02:00
Makefile bpf: fix for lex/yacc build error with gcc-5 2018-04-25 23:27:46 +02:00
Makefile.helpers tools: bpf: build and install man page for eBPF helpers from bpftool/ 2018-07-12 18:55:53 +02:00
bpf_asm.c
bpf_dbg.c bpf: fix uninitialized variable in bpf tools 2018-04-26 22:23:02 +02:00
bpf_exp.l bpf: fix cbpf parser bug for octal numbers 2018-06-03 07:46:55 -07:00
bpf_exp.y
bpf_jit_disasm.c tools/bpf_jit_disasm: silence a static checker warning 2018-01-18 22:15:37 +01:00