Re: [PATCH bpf-next v5 2/3] bpftool: Don't require a disassembler to dump a JITed program to a file
From: Quentin Monnet
Date: Tue Nov 03 2026 - 17:20:28 EST
2026-11-03 18:59 UTC+0500 ~ Mark Korenberg via B4 Relay
<devnull+socketpair.gmail.com@xxxxxxxxxx>
> From: Mark Korenberg <socketpair@xxxxxxxxx>
>
> "bpftool prog dump jited PROG file FILE" only writes the JITed image to
> FILE, but do_dump() calls disasm_init() before it parses the arguments,
> so the command fails when bpftool has no disassembler.
>
> Call disasm_init() only when the image is disassembled.
>
> Fixes: 29a9c10e4110 ("bpftool: make libbfd optional")
> Suggested-by: Alexei Starovoitov <ast@xxxxxxxxxx>
> Signed-off-by: Mark Korenberg <socketpair@xxxxxxxxx>
Acked-by: Quentin Monnet <qmo@xxxxxxxxxx>