summaryrefslogtreecommitdiff
path: root/tools/bpf/bpftool/Documentation/bpftool.rst
diff options
context:
space:
mode:
authorQuentin Monnet <quentin@isovalent.com>2020-09-09 19:24:59 +0300
committerAlexei Starovoitov <ast@kernel.org>2020-09-10 21:16:46 +0300
commitf28ef96d7b04a76575a020a9da4f92358abe68c6 (patch)
treecab44cc5075ad0a04ff13d0d8f80426918661ac3 /tools/bpf/bpftool/Documentation/bpftool.rst
parent82b8cf0acc7bfe7b247e5ddc4417f6146d74c0b8 (diff)
downloadlinux-f28ef96d7b04a76575a020a9da4f92358abe68c6.tar.xz
tools: bpftool: Include common options from separate file
Nearly all man pages for bpftool have the same common set of option flags (--help, --version, --json, --pretty, --debug). The description is duplicated across all the pages, which is more difficult to maintain if the description of an option changes. It may also be confusing to sort out what options are not "common" and should not be copied when creating new manual pages. Let's move the description for those common options to a separate file, which is included with a RST directive when generating the man pages. Signed-off-by: Quentin Monnet <quentin@isovalent.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Acked-by: Andrii Nakryiko <andriin@fb.com> Link: https://lore.kernel.org/bpf/20200909162500.17010-3-quentin@isovalent.com
Diffstat (limited to 'tools/bpf/bpftool/Documentation/bpftool.rst')
-rw-r--r--tools/bpf/bpftool/Documentation/bpftool.rst24
1 files changed, 1 insertions, 23 deletions
diff --git a/tools/bpf/bpftool/Documentation/bpftool.rst b/tools/bpf/bpftool/Documentation/bpftool.rst
index a3629a3f1175..b87f8c2df49d 100644
--- a/tools/bpf/bpftool/Documentation/bpftool.rst
+++ b/tools/bpf/bpftool/Documentation/bpftool.rst
@@ -46,24 +46,7 @@ DESCRIPTION
OPTIONS
=======
- -h, --help
- Print short help message (similar to **bpftool help**).
-
- -V, --version
- Print version number (similar to **bpftool version**), and
- optional features that were included when bpftool was
- compiled. Optional features include linking against libbfd to
- provide the disassembler for JIT-ted programs (**bpftool prog
- dump jited**) and usage of BPF skeletons (some features like
- **bpftool prog profile** or showing pids associated to BPF
- objects may rely on it).
-
- -j, --json
- Generate JSON output. For commands that cannot produce JSON, this
- option has no effect.
-
- -p, --pretty
- Generate human-readable JSON output. Implies **-j**.
+ .. include:: common_options.rst
-m, --mapcompat
Allow loading maps with unknown map definitions.
@@ -72,11 +55,6 @@ OPTIONS
Do not automatically attempt to mount any virtual file system
(such as tracefs or BPF virtual file system) when necessary.
- -d, --debug
- Print all logs available, even debug-level information. This
- includes logs from libbpf as well as from the verifier, when
- attempting to load programs.
-
SEE ALSO
========
**bpf**\ (2),