lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180724154022.3863907-1-kafai@fb.com>
Date:   Tue, 24 Jul 2018 08:40:19 -0700
From:   Martin KaFai Lau <kafai@...com>
To:     <netdev@...r.kernel.org>
CC:     Alexei Starovoitov <ast@...com>,
        Daniel Borkmann <daniel@...earbox.net>, <kernel-team@...com>
Subject: [PATCH v3 bpf 0/3] Introduce BPF_ANNOTATE_KV_PAIR

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.

v3:
- Replace some more *int*_t and u* usages with the
  equivalent __[su]* in btf.c
v2:
- Fix the incorrect '&&' check on container_type
  in bpf_map_find_btf_info().
- Expose the existing static btf_type_by_id() instead of
  creating a new one.

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                          | 39 +++++----
 tools/lib/bpf/btf.h                          | 10 ++-
 tools/lib/bpf/libbpf.c                       | 85 +++++++++++---------
 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, 83 insertions(+), 73 deletions(-)

-- 
2.17.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ