bpftool: auto-complete BTF IDs for btf dump
authorAndrii Nakryiko <andriin@fb.com>
Sun, 26 May 2019 00:01:01 +0000 (17:01 -0700)
committerDaniel Borkmann <daniel@iogearbox.net>
Tue, 28 May 2019 08:50:27 +0000 (10:50 +0200)
commit0d97dacc46d9af2daba1af224747d452bd988365
treef456520f4f72e30a4be99a56ee092d76eed5e750
parentd9a6f413f8c7bd56295098f8b1bf8331af923490
bpftool: auto-complete BTF IDs for btf dump

Auto-complete BTF IDs for `btf dump id` sub-command. List of possible BTF
IDs is scavenged from loaded BPF programs that have associated BTFs, as
there is currently no API in libbpf to fetch list of all BTFs in the
system.

Suggested-by: Quentin Monnet <quentin.monnet@netronome.com>
Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Reviewed-by: Quentin Monnet <quentin.monnet@netronome.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
tools/bpf/bpftool/bash-completion/bpftool