Skip to content

tools: bpftool: print built-in features, automate some of the documentation

Quentin Monnet bpf netdev 3 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest3 patches 3 repliesIn review
  2. v23 patches 0 repliesSuperseded
  3. v13 patches 7 repliesSuperseded

Changes in v3 from the cover letter

- Use a simple list of features (no boolean values) for plain output when dumping built-in features.

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3tools: bpftool: print optional built-in features along with versiontools/bpf/bpftool/Documentation/bpftool.rst tools/bpf/bpftool/main.c+38 -31 reply
2/3tools: bpftool: include common options from separate filetools/bpf/bpftool/Documentation/Makefile tools/bpf/bpftool/Documentation/bpftool-btf.rst tools/bpf/bpftool/Documentation/bpftool-cgroup.rst +11 more+35 -1960 replies
3/3tools: bpftool: automate generation for "SEE ALSO" sections in man pagestools/bpf/bpftool/Documentation/Makefile tools/bpf/bpftool/Documentation/bpftool-btf.rst tools/bpf/bpftool/Documentation/bpftool-cgroup.rst +10 more+11 -1982 replies

Reviews trailers per patch

All 3 patches have a Reviewed-by or Acked-by.

PatchAndrii Nakryiko
1/3A-b
2/3A-b
3/3A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH bpf-next v3 0/3] tools: bpftool: print built-in features, automate some of the documentation

There are two changes for bpftool in this series.

The first one is a modification to the "version" command, to have it print the status (compiled or not) of some of the optional features for bpftool. This is to help determine if a bpftool binary is able to, for example, disassemble JIT-compiled programs.

The last two patches try to automate the generation of some repetitive sections in the man pages for bpftool, namely the description of the options shared by all commands, and the "see also" section. The objective is to make it easier to maintain the pages and to reduce the risk of omissions when adding the documentation for new commands.

v3:
- Use a simple list of features (no boolean values) for plain output when dumping built-in features.

v2:
- Fix incorrect JSON output.
- Use "echo -n" instead of "printf" in Makefile to avoid the risk of passing and evaluating formatting strings.

Quentin Monnet (3):
tools: bpftool: print optional built-in features along with version
tools: bpftool: include common options from separate file
tools: bpftool: automate generation for "SEE ALSO" sections in man
pages

 tools/bpf/bpftool/Documentation/Makefile      | 14 ++++++--
 .../bpf/bpftool/Documentation/bpftool-btf.rst | 34 +-----------------
 .../bpftool/Documentation/bpftool-cgroup.rst  | 33 +----------------
 .../bpftool/Documentation/bpftool-feature.rst | 33 +----------------
 .../bpf/bpftool/Documentation/bpftool-gen.rst | 33 +----------------
 .../bpftool/Documentation/bpftool-iter.rst    | 27 +-------------
 .../bpftool/Documentation/bpftool-link.rst    | 34 +-----------------
 .../bpf/bpftool/Documentation/bpftool-map.rst | 33 +----------------
 .../bpf/bpftool/Documentation/bpftool-net.rst | 34 +-----------------
 .../bpftool/Documentation/bpftool-perf.rst    | 34 +-----------------
 .../bpftool/Documentation/bpftool-prog.rst    | 34 +-----------------
 .../Documentation/bpftool-struct_ops.rst      | 35 +------------------
 tools/bpf/bpftool/Documentation/bpftool.rst   | 34 +-----------------
 .../bpftool/Documentation/common_options.rst  | 22 ++++++++++++
 tools/bpf/bpftool/main.c                      | 33 +++++++++++++++--
 15 files changed, 77 insertions(+), 390 deletions(-)
 create mode 100644 tools/bpf/bpftool/Documentation/common_options.rst
Signature · 1 line
2.25.1