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: <87sgitu1av.fsf@toke.dk>
Date:   Sat, 29 Feb 2020 11:37:28 +0100
From:   Toke Høiland-Jørgensen <toke@...hat.com>
To:     Andrii Nakryiko <andrii.nakryiko@...il.com>
Cc:     Alexei Starovoitov <ast@...nel.org>,
        Daniel Borkmann <daniel@...earbox.net>,
        Martin KaFai Lau <kafai@...com>,
        Song Liu <songliubraving@...com>, Yonghong Song <yhs@...com>,
        Andrii Nakryiko <andriin@...com>,
        "David S. Miller" <davem@...emloft.net>,
        Jakub Kicinski <kuba@...nel.org>,
        Jesper Dangaard Brouer <brouer@...hat.com>,
        John Fastabend <john.fastabend@...il.com>,
        Lorenz Bauer <lmb@...udflare.com>,
        Andrey Ignatov <rdna@...com>,
        Networking <netdev@...r.kernel.org>, bpf <bpf@...r.kernel.org>
Subject: Re: [PATCH RFC] Userspace library for handling multiple XDP programs on an interface

Andrii Nakryiko <andrii.nakryiko@...il.com> writes:

> On Fri, Feb 28, 2020 at 6:22 AM Toke Høiland-Jørgensen <toke@...hat.com> wrote:
>>
>> Hi everyone
>>
>> As most of you are no doubt aware, we've had various discussions on how
>> to handle multiple XDP programs on a single interface. With the freplace
>> functionality, the kernel infrastructure is now there to handle this
>> (almost, see "missing pieces" below).
>>
>> While the freplace mechanism offers userspace a lot of flexibility in
>> how to handle dispatching of multiple XDP programs, userspace also has
>> to do quite a bit of work to implement this (compared to just issuing
>> load+attach). The goal of this email is to get some feedback on a
>> library to implement this, in the hope that we can converge on something
>> that will be widely applicable, ensuring that both (a) everyone doesn't
>> have to reinvent the wheel, and (b) we don't end up with a proliferation
>> of subtly incompatible dispatcher models that makes it hard or
>> impossible to mix and match XDP programs from multiple sources.
>>
>
> [...]
>
>>
>> **** Missing pieces
>> While the libxdp code can assemble a basic dispatcher and load it into the
>> kernel, there are a couple of missing pieces on the kernel side; I will propose
>> patches to fix these, but figured there was no reason to hold back posting of
>> the library for comments because of this. These missing pieces are:
>>
>> - There is currently no way to persist the freplace after the program exits; the
>>   file descriptor returned by bpf_raw_tracepoint_open() will release the program
>>   when it is closed, and it cannot be pinned.
>
> This is completely addressed by patch set [0] I just posted. It will
> allow you to pin freplace BPF link in BPF FS. Feel free to review and
> comment there, if anything is missing.
>
>   [0]
>   https://patchwork.ozlabs.org/project/netdev/list/?series=161582&state=*

Ah, excellent! I'll take a look, thanks for the pointer :)

-Toke

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ