Commit Graph

8 Commits

Author SHA1 Message Date
Yonghong Song
5844f6e4dd sync: latest libbpf changes from kernel
Syncing latest libbpf commits from kernel repository.
Baseline commit:   50bd645b3a21a374dbd0fa8273a5f4e98001fb05
Checkpoint commit: 3daf8e703ec3dcf73a27a7dcabbac152793eb114

Andrey Ignatov (1):
  libbpf: Fix build with gcc-8

Stanislav Fomichev (1):
  libbpf: add support for ctx_{size, }_{in, out} in BPF_PROG_TEST_RUN

 include/uapi/linux/bpf.h | 7 +++++++
 src/bpf.c                | 5 +++++
 src/bpf.h                | 5 +++++
 src/libbpf.c             | 2 +-
 4 files changed, 18 insertions(+), 1 deletion(-)

--
2.17.1
2019-04-11 09:01:12 -07:00
Yonghong Song
f49907472f sync: latest libbpf changes from kernel
Syncing latest libbpf commits from kernel repository.
Baseline commit:   dd399ac9e343c7573c47d6820e4a23013c54749d
Checkpoint commit: 50bd645b3a21a374dbd0fa8273a5f4e98001fb05

Alexei Starovoitov (1):
  libbpf: teach libbpf about log_level bit 2

Andrey Ignatov (1):
  libbpf: Ignore -Wformat-nonliteral warning

Daniel Borkmann (3):
  bpf: sync {btf, bpf}.h uapi header from tools infrastructure
  bpf, libbpf: support global data/bss/rodata sections
  bpf, libbpf: add support for BTF Var and DataSec

Joe Stringer (1):
  bpf, libbpf: refactor relocation handling

Magnus Karlsson (1):
  libbpf: fix crash in XDP socket part with new larger BPF_LOG_BUF_SIZE

Yonghong Song (1):
  bpf, bpftool: fix a few ubsan warnings

 include/uapi/linux/bpf.h |  20 +-
 include/uapi/linux/btf.h |  32 ++-
 src/bpf.c                |  31 ++-
 src/bpf.h                |   3 +-
 src/btf.c                |  97 ++++++-
 src/btf.h                |   3 +
 src/libbpf.c             | 567 ++++++++++++++++++++++++++++++++-------
 src/libbpf.h             |   6 +
 src/libbpf.map           |   7 +
 src/xsk.c                |   9 +-
 10 files changed, 658 insertions(+), 117 deletions(-)

--
2.17.1
2019-04-10 14:27:33 -07:00
Andrii Nakryiko
27a5f60a8b sync: latest libbpf changes from kernel
Syncing latest libbpf commits from kernel repository.
Baseline commit:   f01a7dbe98ae4265023fa5d3af0f076f0b18a647
Checkpoint commit: dd399ac9e343c7573c47d6820e4a23013c54749d

Arnaldo Carvalho de Melo (1):
  tools lib bpf: Fix the build by adding a missing stdarg.h include

Changbin Du (1):
  perf tools: Fix errors under optimization level '-Og'

Daniel Borkmann (1):
  bpf, libbpf: clarify bump in libbpf version info

Lorenz Bauer (1):
  tools: update include/uapi/linux/bpf.h

Luca Boccassi (1):
  tools/bpf: generate pkg-config file for libbpf

Song Liu (1):
  tools lib bpf: Introduce bpf_program__get_prog_info_linear()

Willem de Bruijn (1):
  bpf: Sync bpf.h to tools

 include/uapi/linux/bpf.h |  65 +++++++++-
 src/README.rst           |   1 +
 src/libbpf.c             | 253 ++++++++++++++++++++++++++++++++++++++-
 src/libbpf.h             |  64 ++++++++++
 src/libbpf.map           |   3 +
 src/libbpf.pc.template   |  12 ++
 6 files changed, 393 insertions(+), 5 deletions(-)
 create mode 100644 src/libbpf.pc.template

--
2.17.1
2019-03-28 19:51:55 -07:00
Andrii Nakryiko
5877849633 sync: latest libbpf changes from kernel
Syncing latest libbpf commits from kernel repository.
Baseline commit:   f01a7dbe98ae4265023fa5d3af0f076f0b18a647
Checkpoint commit: 8543e437807970166c2b66b79935c9f4b0e6d1f9

Andrii Nakryiko (1):
  libbpf: fix btf_dedup equivalence check handling of different kinds

Daniel Borkmann (1):
  bpf, libbpf: clarify bump in libbpf version info

 src/README.rst | 1 +
 src/btf.c      | 3 +++
 2 files changed, 4 insertions(+)

--
2.17.1
2019-03-28 19:51:55 -07:00
Andrii Nakryiko
33b0174985 sync: latest libbpf changes from kernel
Syncing latest libbpf commits from kernel repository.
Baseline commit:   ea5bade929bf04355aeed58a3c9f5ef2c3afe2ac
Checkpoint commit: f01a7dbe98ae4265023fa5d3af0f076f0b18a647

Andrii Nakryiko (2):
  libbpf: handle BTF parsing and loading properly
  btf: resolve enum fwds in btf_dedup

Magnus Karlsson (1):
  libbpf: fix to reject unknown flags in xsk_socket__create()

Martin KaFai Lau (1):
  bpf: Sync bpf.h to tools/

Nikita V. Shirokov (1):
  bpf, libbpf: fixing leak when kernel does not support btf

Quentin Monnet (1):
  tools: bpf: synchronise BPF UAPI header with tools

 include/uapi/linux/bpf.h | 188 ++++++++++++++++++++++++++-------------
 src/btf.c                |  51 ++++++++---
 src/libbpf.c             |  11 ++-
 src/xsk.c                |  15 +++-
 4 files changed, 186 insertions(+), 79 deletions(-)

--
2.17.1
2019-03-19 12:17:19 -07:00
Andrii Nakryiko
7a431904c8 sync: latest libbpf changes from kernel
Syncing latest libbpf commits from kernel repository.
Baseline commit:   5aab392c55c96f9bb26d9294f965f156a87ee81c
Checkpoint commit: ea5bade929bf04355aeed58a3c9f5ef2c3afe2ac

Alexei Starovoitov (1):
  tools/bpf: sync bpf.h into tools

Andrii Nakryiko (3):
  libbpf: fix formatting for btf_ext__get_raw_data
  btf: allow to customize dedup hash table size
  btf: fix bug with resolving STRUCT/UNION into corresponding FWD

Dan Carpenter (1):
  tools/libbpf: signedness bug in btf_dedup_ref_type()

Jakub Kicinski (1):
  tools: libbpf: add a correctly named define for map iteration

Magnus Karlsson (1):
  libbpf: add support for using AF_XDP sockets

brakmo (1):
  bpf: sync bpf.h to tools and update bpf_helpers.h

 include/uapi/linux/bpf.h |  12 +-
 src/README.rst           |  15 +-
 src/btf.c                |  76 ++--
 src/btf.h                |   3 +-
 src/libbpf.c             |   8 +-
 src/libbpf.h             |   3 +-
 src/libbpf.map           |   6 +
 src/xsk.c                | 723 +++++++++++++++++++++++++++++++++++++++
 src/xsk.h                | 203 +++++++++++
 9 files changed, 1020 insertions(+), 29 deletions(-)
 create mode 100644 src/xsk.c
 create mode 100644 src/xsk.h

--
2.17.1
2019-03-02 21:31:13 -08:00
Andrii Nakryiko
d5fa4150f0 libbpf sync 2019-02-17T06:35:29.358Z (#14)
* tools/libbpf: support bigger BTF data sizes

While it's understandable why kernel limits number of BTF types to 65535
and size of string section to 64KB, in libbpf as user-space library it's
too restrictive. E.g., pahole converting DWARF to BTF type information
for Linux kernel generates more than 3 million BTF types and more than
3MB of strings, before deduplication. So to allow btf__dedup() to do its
work, we need to be able to load bigger BTF sections using btf__new().

Singed-off-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>

* sync: latest libbpf changes from kernel

Syncing latest libbpf commits from kernel repository.
Baseline commit:   789f6bab849e04ea029c09b81dc8401dc0268cf9
Checkpoint commit: 5aab392c55c96f9bb26d9294f965f156a87ee81c

Andrii Nakryiko (1):
  tools/libbpf: support bigger BTF data sizes

 src/btf.c | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

--
2.17.1
2019-02-16 22:41:31 -08:00
Andrii Nakryiko
8e42f42533 scripts: add script to sync kernel changes (#13)
This script automates the process of applying libbpf-relevant changes
from kernel repository on top of current state of libbpf repository.

It uses CHECKPOINT-COMMIT file to keep track of last commit in kernel
repo up to which libbpf is in sync with. If there are any new libbpf
changes in kernel repository, script extracts them, preserving original
commit metadata. It also creates a "sync commit" using cover letter as
a template, which nicely summarizes changes since last sync with kernel.

Usage: ./scripts/sync-kernel.sh <linux-repo> <libbpf-repo>

If it succeeds, script will create a bunch of local commits in
<libbpf-repo> in separate branch, which can be easily pushed into github
to create a pull request.

Script tries to clean up after itself, except in case of failure. But it
doesn't clean up timestamped branches it creates in both kernel and
libbpf repositories for now. We can add that later.

Signed-off-by: Andrii Nakryiko <andriin@fb.com>
2019-02-16 22:22:30 -08:00