mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH bpf-next v2 0/3] bpf: account for local storage map elements memory
@ 2026-11-30 20:14 Mahe Tardy
  2026-11-30 20:14 ` [PATCH bpf-next v2 1/3] bpf: reuse local storage map link and unlink helpers Mahe Tardy
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Mahe Tardy @ 2026-11-30 20:14 UTC (permalink / raw)
  To: bpf
  Cc: Andrii Nakryiko, Eduard Zingerman, Ihor Solodrai,
	Alexei Starovoitov, Daniel Borkmann, Kumar Kartikeya Dwivedi,
	Martin KaFai Lau, Song Liu, Yonghong Song, Jiri Olsa,
	Emil Tsalapatis, linux-kernel, John Fastabend, Mahe Tardy

We started using task local storage within Tetragon and realized memlock
omitted the memory used by map entries[^1] which is significant in our
use case, this aims at making the memory usage more accurate.

v2 changes:
- use map->elem_count instead of walking the elements (alexei)

Link to v1: https://lore.kernel.org/bpf/20261126131318.470837-1-mahe.tardy@gmail.com/

[^1]: https://github.com/cilium/tetragon/issues/6139

Mahe Tardy (3):
  bpf: reuse local storage map link and unlink helpers
  bpf: account for local storage map elements memory
  selftests/bpf: test task storage memory accounting

 kernel/bpf/bpf_local_storage.c                | 41 ++++++++-----
 .../bpf/prog_tests/task_local_storage.c       | 61 +++++++++++++++++++
 2 files changed, 87 insertions(+), 15 deletions(-)

--
2.43.0


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

end of thread, other threads:[~2026-11-30 20:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-30 20:14 [PATCH bpf-next v2 0/3] bpf: account for local storage map elements memory Mahe Tardy
2026-11-30 20:14 ` [PATCH bpf-next v2 1/3] bpf: reuse local storage map link and unlink helpers Mahe Tardy
2026-11-30 20:14 ` [PATCH bpf-next v2 2/3] bpf: account for local storage map elements memory Mahe Tardy
2026-11-30 20:14 ` [PATCH bpf-next v2 3/3] selftests/bpf: test task storage memory accounting Mahe Tardy

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

all inboxes | Powered by JetHome®