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-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5a48c2f1-2abc-2deb-6863-c9f20e4ac03b@iogearbox.net>
Date:   Wed, 3 Jul 2019 11:36:15 +0200
From:   Daniel Borkmann <daniel@...earbox.net>
To:     Andrii Nakryiko <andriin@...com>, andrii.nakryiko@...il.com,
        ast@...com, kernel-team@...com, bpf@...r.kernel.org,
        netdev@...r.kernel.org, jakub.kicinski@...ronome.com
Subject: Re: [PATCH v4 bpf-next 0/4] libbpf: add perf buffer abstraction and
 API

On 06/30/2019 08:51 AM, Andrii Nakryiko wrote:
> This patchset adds a high-level API for setting up and polling perf buffers
> associated with BPF_MAP_TYPE_PERF_EVENT_ARRAY map. Details of APIs are
> described in corresponding commit.
> 
> Patch #1 adds a set of APIs to set up and work with perf buffer.
> Patch #2 enhances libbpf to support auto-setting PERF_EVENT_ARRAY map size.
> Patch #3 adds test.
> Patch #4 converts bpftool map event_pipe to new API.
> 
> v3->v4:
> - fixed bpftool event_pipe cmd error handling (Jakub);
> 
> v2->v3:
> - added perf_buffer__new_raw for more low-level control;
> - converted bpftool map event_pipe to new API (Daniel);
> - fixed bug with error handling in create_maps (Song);
> 
> v1->v2:
> - add auto-sizing of PERF_EVENT_ARRAY maps;
> 
> Andrii Nakryiko (4):
>   libbpf: add perf buffer API
>   libbpf: auto-set PERF_EVENT_ARRAY size to number of CPUs
>   selftests/bpf: test perf buffer API
>   tools/bpftool: switch map event_pipe to libbpf's perf_buffer
> 
>  tools/bpf/bpftool/map_perf_ring.c             | 201 +++------
>  tools/lib/bpf/libbpf.c                        | 397 +++++++++++++++++-
>  tools/lib/bpf/libbpf.h                        |  49 +++
>  tools/lib/bpf/libbpf.map                      |   4 +
>  .../selftests/bpf/prog_tests/perf_buffer.c    |  94 +++++
>  .../selftests/bpf/progs/test_perf_buffer.c    |  29 ++
>  6 files changed, 630 insertions(+), 144 deletions(-)
>  create mode 100644 tools/testing/selftests/bpf/prog_tests/perf_buffer.c
>  create mode 100644 tools/testing/selftests/bpf/progs/test_perf_buffer.c

Hm, set looks good, but this does not apply cleanly. Please rebase against
bpf-next and resubmit. Please also update tools/lib/bpf/README.rst with regards
to the perf_buffer__ prefix. While at it, you could also address Jakub's comment.

Thanks,
Daniel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ