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] [day] [month] [year] [list]
Message-ID: <CAEf4BzaD6j=MFkHAK344BaqBihoE-Ym5ahxvL2x_mgRHn1S2Lw@mail.gmail.com>
Date:   Wed, 30 Oct 2019 15:02:54 -0700
From:   Andrii Nakryiko <andrii.nakryiko@...il.com>
To:     Alexei Starovoitov <ast@...nel.org>
Cc:     "David S. Miller" <davem@...emloft.net>,
        Daniel Borkmann <daniel@...earbox.net>,
        Networking <netdev@...r.kernel.org>, bpf <bpf@...r.kernel.org>,
        Kernel Team <kernel-team@...com>
Subject: Re: [PATCH bpf-next 1/2] bpf: replace prog_raw_tp+btf_id with prog_tracing

On Wed, Oct 30, 2019 at 12:36 PM Alexei Starovoitov <ast@...nel.org> wrote:
>
> The bpf program type raw_tp together with 'expected_attach_type'
> was the most appropriate api to indicate BTF-enabled raw_tp programs.
> But during development it became apparent that 'expected_attach_type'
> cannot be used and new 'attach_btf_id' field had to be introduced.
> Which means that the information is duplicated in two fields where
> one of them is ignored.
> Clean it up by introducing new program type where both
> 'expected_attach_type' and 'attach_btf_id' fields have
> specific meaning.
> In the future 'expected_attach_type' will be extended
> with other attach points that have similar semantics to raw_tp.
> This patch is replacing BTF-enabled BPF_PROG_TYPE_RAW_TRACEPOINT with
> prog_type = BPF_RPOG_TYPE_TRACING
> expected_attach_type = BPF_TRACE_RAW_TP
> attach_btf_id = btf_id of raw tracepoint inside the kernel
> Future patches will add
> expected_attach_type = BPF_TRACE_FENTRY or BPF_TRACE_FEXIT
> where programs have the same input context and the same helpers,
> but different attach points.
>
> Signed-off-by: Alexei Starovoitov <ast@...nel.org>
> ---

LGTM.

Acked-by: Andrii Nakryiko <andriin@...com>

>  include/linux/bpf.h       |  5 +++++
>  include/linux/bpf_types.h |  1 +
>  include/uapi/linux/bpf.h  |  2 ++
>  kernel/bpf/syscall.c      |  6 +++---
>  kernel/bpf/verifier.c     | 34 +++++++++++++++++++++---------
>  kernel/trace/bpf_trace.c  | 44 ++++++++++++++++++++++++++++++++-------
>  6 files changed, 71 insertions(+), 21 deletions(-)
>

[...]

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ