Netdev List
 help / color / mirror / Atom feed
* [PATCH bpf 0/3] Introduce BPF_ANNOTATE_KV_PAIR
@ 2018-07-21  1:39 Martin KaFai Lau
  2018-07-21  1:39 ` [PATCH bpf 1/3] bpf: btf: Sync uapi btf.h to tools Martin KaFai Lau
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Martin KaFai Lau @ 2018-07-21  1:39 UTC (permalink / raw)
  To: netdev; +Cc: Alexei Starovoitov, Daniel Borkmann, kernel-team

The series allows the BPF loader to figure out
the btf_key_id and btf_value_id from a map's name
by using BPF_ANNOTATE_KV_PAIR.  It also removes
the old 'typedef' way which requires two separate
typedefs (one for the key and one for the value).

By doing this, iproute2 and libbpf have one
consistent way to figure out the btf_key_type_id and
btf_value_type_id for a map.

The first two patches are some prep/cleanup works.
The last patch introduces BPF_ANNOTATE_KV_PAIR.

Martin KaFai Lau (3):
  bpf: btf: Sync uapi btf.h to tools
  bpf: Replace [u]int32_t and [u]int64_t in libbpf
  bpf: Introduce BPF_ANNOTATE_KV_PAIR

 tools/include/uapi/linux/btf.h               |  2 +-
 tools/lib/bpf/btf.c                          | 36 +++++----
 tools/lib/bpf/btf.h                          |  9 ++-
 tools/lib/bpf/libbpf.c                       | 81 +++++++++++---------
 tools/lib/bpf/libbpf.h                       |  4 +-
 tools/testing/selftests/bpf/bpf_helpers.h    |  9 +++
 tools/testing/selftests/bpf/test_btf_haskv.c |  7 +-
 7 files changed, 84 insertions(+), 64 deletions(-)

-- 
2.17.1

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

end of thread, other threads:[~2018-07-21 18:08 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-07-21  1:39 [PATCH bpf 0/3] Introduce BPF_ANNOTATE_KV_PAIR Martin KaFai Lau
2018-07-21  1:39 ` [PATCH bpf 1/3] bpf: btf: Sync uapi btf.h to tools Martin KaFai Lau
2018-07-21  1:39 ` [PATCH bpf 2/3] bpf: Replace [u]int32_t and [u]int64_t in libbpf Martin KaFai Lau
2018-07-21  1:39 ` [PATCH bpf 3/3] bpf: Introduce BPF_ANNOTATE_KV_PAIR Martin KaFai Lau
2018-07-21 17:06   ` Martin KaFai Lau

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