Skip to content

tools: bpftool: update, synchronise and validate types and options

Quentin Monnet bpf netdev 2 versions – Applied

Status from this message: This series was applied to bpf/bpf-next.git (refs/heads/master):

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest7 patches 0 repliesApplied 7/7
  2. v17 patches 11 repliesSuperseded

Changes in v2 from the cover letter

- Reformat some lines in the bash completion file.
- Do not reformat attach types, to preserve git-blame history.
- Do not call Python script from tools/testing/selftests/bpf/Makefile.

Patches in v2 All 7 applied

#Subject and filesSizeRepliesApplied
1/7tools: bpftool: slightly ease bash completion updatestools/bpf/bpftool/bash-completion/bpftool+29 -250 repliesApplied
2/7selftests/bpf: check consistency between bpftool source, doc, completiontools/testing/selftests/bpf/test_bpftool_synctypes.py+486 -00 repliesApplied
3/7tools: bpftool: complete and synchronise attach or map typestools/bpf/bpftool/Documentation/bpftool-prog.rst tools/bpf/bpftool/bash-completion/bpftool tools/bpf/bpftool/common.c +1 more+12 -50 repliesApplied
4/7tools: bpftool: update and synchronise option list in doc and help msgtools/bpf/bpftool/Documentation/bpftool-btf.rst tools/bpf/bpftool/Documentation/bpftool-cgroup.rst tools/bpf/bpftool/Documentation/bpftool-feature.rst +22 more+45 -280 repliesApplied
5/7selftests/bpf: update bpftool's consistency script for checking optionstools/testing/selftests/bpf/test_bpftool_synctypes.py+111 -110 repliesApplied
6/7tools: bpftool: document and add bash completion for -L, -B optionstools/bpf/bpftool/Documentation/bpftool-btf.rst tools/bpf/bpftool/Documentation/bpftool-gen.rst tools/bpf/bpftool/Documentation/bpftool-prog.rst +5 more+96 -100 repliesApplied
7/7tools: bpftool: complete metrics list in "bpftool prog profile" doctools/bpf/bpftool/Documentation/bpftool-prog.rst tools/bpf/bpftool/bash-completion/bpftool+4 -20 repliesApplied

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.

Read the v2 thread

Cover letter [PATCH bpf-next v2 0/7] tools: bpftool: update, synchronise and validate types and options

To work with the different program types, map types, attach types etc. supported by eBPF, bpftool needs occasional updates to learn about the new features supported by the kernel. When such types translate into new keyword for the command line, updates are expected in several locations:
typically, the help message displayed from bpftool itself, the manual page, and the bash completion file should be updated. The options used by the different commands for bpftool should also remain synchronised at those locations.

Several omissions have occurred in the past, and a number of types are still missing today. This set is an attempt to improve the situation. It brings up-to-date the lists of types or options in bpftool, and also adds a Python script to the BPF selftests to automatically check that most of these lists remain synchronised.

v2:
- Reformat some lines in the bash completion file.
- Do not reformat attach types, to preserve git-blame history.
- Do not call Python script from tools/testing/selftests/bpf/Makefile.

Quentin Monnet (7):
tools: bpftool: slightly ease bash completion updates selftests/bpf: check consistency between bpftool source, doc,
completion
tools: bpftool: complete and synchronise attach or map types
tools: bpftool: update and synchronise option list in doc and help msg selftests/bpf: update bpftool's consistency script for checking
options
tools: bpftool: document and add bash completion for -L, -B options
tools: bpftool: complete metrics list in "bpftool prog profile" doc

 .../bpf/bpftool/Documentation/bpftool-btf.rst |  48 +-
 .../bpftool/Documentation/bpftool-cgroup.rst  |   3 +-
 .../bpftool/Documentation/bpftool-feature.rst |   2 +-
 .../bpf/bpftool/Documentation/bpftool-gen.rst |   9 +-
 .../bpftool/Documentation/bpftool-iter.rst    |   2 +
 .../bpftool/Documentation/bpftool-link.rst    |   3 +-
 .../bpf/bpftool/Documentation/bpftool-map.rst |   3 +-
 .../bpf/bpftool/Documentation/bpftool-net.rst |   2 +-
 .../bpftool/Documentation/bpftool-perf.rst    |   2 +-
 .../bpftool/Documentation/bpftool-prog.rst    |  36 +-
 .../Documentation/bpftool-struct_ops.rst      |   2 +-
 tools/bpf/bpftool/Documentation/bpftool.rst   |  12 +-
 tools/bpf/bpftool/bash-completion/bpftool     |  66 +-
 tools/bpf/bpftool/btf.c                       |   3 +-
 tools/bpf/bpftool/cgroup.c                    |   3 +-
 tools/bpf/bpftool/common.c                    |   6 +
 tools/bpf/bpftool/feature.c                   |   1 +
 tools/bpf/bpftool/gen.c                       |   3 +-
 tools/bpf/bpftool/iter.c                      |   2 +
 tools/bpf/bpftool/link.c                      |   3 +-
 tools/bpf/bpftool/main.c                      |   3 +-
 tools/bpf/bpftool/main.h                      |   3 +-
 tools/bpf/bpftool/map.c                       |   5 +-
 tools/bpf/bpftool/net.c                       |   1 +
 tools/bpf/bpftool/perf.c                      |   5 +-
 tools/bpf/bpftool/prog.c                      |   8 +-
 tools/bpf/bpftool/struct_ops.c                |   2 +-
 .../selftests/bpf/test_bpftool_synctypes.py   | 586 ++++++++++++++++++
 28 files changed, 763 insertions(+), 61 deletions(-)
 create mode 100755 tools/testing/selftests/bpf/test_bpftool_synctypes.py
Signature · 1 line
2.30.2