Skip to content

libbpf 1.0: deprecate bpf_map__def() API

Christy Lee bpf linux-perf-users 2 versions – Applied

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

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest5 patches 0 repliesApplied 5/5
  2. v15 patches 2 repliesSuperseded

Changes in v2 from the cover letter

https://lore.kernel.org/all/[email protected]/

* Fixed commit messages to match commit titles
* Fixed indentation
* Removed bpf_map__def() usage that was missed in v1

Patches in v2 All 5 applied

#Subject and filesSizeRepliesApplied
1/5samples/bpf: stop using bpf_map__def() APIsamples/bpf/xdp_rxq_info_user.c+5 -50 repliesApplied
2/5bpftool: stop using bpf_map__def() APItools/bpf/bpftool/gen.c tools/bpf/bpftool/struct_ops.c+7 -90 repliesApplied
3/5perf: stop using bpf_map__def() APItools/perf/util/bpf-loader.c tools/perf/util/bpf_map.c+41 -510 repliesApplied
4/5selftests/bpf: stop using bpf_map__def() APItools/testing/selftests/bpf/prog_tests/flow_dissector.c tools/testing/selftests/bpf/prog_tests/global_data.c tools/testing/selftests/bpf/prog_tests/global_data_init.c +2 more+26 -280 repliesApplied
5/5libbpf: deprecate bpf_map__def() APItools/lib/bpf/libbpf.h+2 -10 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/5] libbpf 1.0: deprecate bpf_map__def() API

bpf_map__def() is rarely used and non-extensible. bpf_map_def fields can be accessed with appropriate map getters and setters instead. Deprecate bpf_map__def() API and replace use cases with getters and setters.

Changelog:
----------
v1 -> v2:
https://lore.kernel.org/all/[email protected]/

* Fixed commit messages to match commit titles
* Fixed indentation
* Removed bpf_map__def() usage that was missed in v1

Christy Lee (5):
samples/bpf: stop using bpf_map__def() API
bpftool: stop using bpf_map__def() API
perf: stop using bpf_map__def() API
selftests/bpf: stop using bpf_map__def() API
libbpf: deprecate bpf_map__def() API

 samples/bpf/xdp_rxq_info_user.c               | 10 +--
 tools/bpf/bpftool/gen.c                       | 12 ++--
 tools/bpf/bpftool/struct_ops.c                |  4 +-
 tools/lib/bpf/libbpf.h                        |  3 +-
 tools/perf/util/bpf-loader.c                  | 64 ++++++++-----------
 tools/perf/util/bpf_map.c                     | 28 ++++----
 .../selftests/bpf/prog_tests/flow_dissector.c |  2 +-
 .../selftests/bpf/prog_tests/global_data.c    |  2 +-
 .../bpf/prog_tests/global_data_init.c         |  2 +-
 .../selftests/bpf/prog_tests/sockmap_listen.c | 12 ++--
 .../selftests/bpf/prog_tests/tailcalls.c      | 36 +++++------
 11 files changed, 81 insertions(+), 94 deletions(-)

--
2.30.2