Linux Kernel Selftest development
 help / color / mirror / Atom feed
* [PATCH bpf-next 0/2] bpftool: Reset map info between queries
@ 2026-09-28 17:18 Tianyi Chen
  2026-09-28 17:13 ` [PATCH bpf-next 2/2] selftests/bpf: Check bpftool map info across mixed BTF maps Tianyi Chen
  2026-09-28 17:13 ` [PATCH bpf-next 1/2] bpftool: Reset map info before each query in show and dump loops Tianyi Chen
  0 siblings, 2 replies; 5+ messages in thread
From: Tianyi Chen @ 2026-09-28 17:18 UTC (permalink / raw)
  To: bpf; +Cc: qmo, andrii, eddyz87, ihor.solodrai, linux-kselftest,
	skokovmaksimevg

Reset map info before each query in the existing show and dump loops
to prevent BTF metadata from a preceding map leaking into a map without
BTF.

Patch 1 fixes the four query loops. Patch 2 adds regression tests for
full and named listings, JSON dumps, and plain dumps.

All four regression subtests fail on the unmodified bpf-next base and
pass with the fix in an x86-64 VM. This series does not depend on
recursive dumping or Maxim's series.

Tianyi Chen (2):
  bpftool: Reset map info before each query in show and dump loops
  selftests/bpf: Check bpftool map info across mixed BTF maps

 tools/bpf/bpftool/map.c                       |   8 ++
 .../bpf/prog_tests/bpftool_map_info.c         | 126 ++++++++++++++++++
 2 files changed, 134 insertions(+)
 create mode 100644 tools/testing/selftests/bpf/prog_tests/bpftool_map_info.c


base-commit: ea9358e1270ab2c3ba6f36bd9bdda68617665516
-- 
2.55.0


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-09-29 10:29 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-28 17:18 [PATCH bpf-next 0/2] bpftool: Reset map info between queries Tianyi Chen
2026-09-28 17:13 ` [PATCH bpf-next 2/2] selftests/bpf: Check bpftool map info across mixed BTF maps Tianyi Chen
2026-09-29 10:28   ` Quentin Monnet
2026-09-28 17:13 ` [PATCH bpf-next 1/2] bpftool: Reset map info before each query in show and dump loops Tianyi Chen
2026-09-29 10:28   ` Quentin Monnet

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox