mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-15 16:53:54 +08:00
tools: bpftool: fix warning on struct bpf_prog_linfo definition
The following warning appears when compiling bpftool without BFD
support:
main.h:198:23: warning: 'struct bpf_prog_linfo' declared inside
parameter list will not be visible outside of this definition or
declaration
const struct bpf_prog_linfo *prog_linfo,
Fix it by declaring struct bpf_prog_linfo even in the case BFD is not
supported.
Fixes: b053b439b7
("bpf: libbpf: bpftool: Print bpf_line_info during prog dump")
Signed-off-by: Quentin Monnet <quentin.monnet@netronome.com>
Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
This commit is contained in:
parent
bd0fb9d007
commit
8c03ecf712
@ -147,8 +147,8 @@ int prog_parse_fd(int *argc, char ***argv);
|
||||
int map_parse_fd(int *argc, char ***argv);
|
||||
int map_parse_fd_and_info(int *argc, char ***argv, void *info, __u32 *info_len);
|
||||
|
||||
#ifdef HAVE_LIBBFD_SUPPORT
|
||||
struct bpf_prog_linfo;
|
||||
#ifdef HAVE_LIBBFD_SUPPORT
|
||||
void disasm_print_insn(unsigned char *image, ssize_t len, int opcodes,
|
||||
const char *arch, const char *disassembler_options,
|
||||
const struct btf *btf,
|
||||
|
Loading…
Reference in New Issue
Block a user