linux-sg2042/tools/net
David Daney b6518e6a00 tools: bpf_jit_disasm: Add option to dump JIT image to a file.
When debugging the JIT on an embedded platform or cross build
environment, libbfd may not be available, making it impossible to run
bpf_jit_disasm natively.

Add an option to emit a binary image of the JIT code to a file.  This
file can then be disassembled off line.  Typical usage in this case
might be (pasting mips64 dmesg output to cat command):

   $ cat > jit.raw
   $ bpf_jit_disasm -f jit.raw -O jit.bin
   $ mips64-linux-gnu-objdump -D -b binary -m mips:isa64r2 -EB jit.bin

Signed-off-by: David Daney <david.daney@cavium.com>
Acked-by: Daniel Borkmann <daniel@iogearbox.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-04-13 13:04:03 -04:00
..
Makefile tools/net: Use include/uapi with __EXPORTED_HEADERS__ 2015-11-15 17:24:33 -05:00
bpf_asm.c filter: bpf_asm: add minimal bpf asm tool 2013-12-11 20:28:35 -05:00
bpf_dbg.c bpf_dbg: do not initialise statics to 0 2016-02-11 04:24:45 -05:00
bpf_exp.l tools, bpf_asm: simplify parser rule for BPF extensions 2016-02-22 13:29:42 -05:00
bpf_exp.y tools, bpf_asm: simplify parser rule for BPF extensions 2016-02-22 13:29:42 -05:00
bpf_jit_disasm.c tools: bpf_jit_disasm: Add option to dump JIT image to a file. 2017-04-13 13:04:03 -04:00