Re: [PATCH bpf-next V1] bpf: devmap dynamic map-value area based on BTF

2020-06-09 Thread Jesper Dangaard Brouer
On Fri, 5 Jun 2020 09:58:26 -0700 Alexei Starovoitov wrote: > On Fri, Jun 5, 2020 at 1:23 AM Jesper Dangaard Brouer > wrote: > > > > Great. If we can remove this requirement of -1 init (and let zero mean > > feature isn't used), then I'm all for exposing expose in uapi/bpf.h. > > Not having

Re: [PATCH bpf-next V1] bpf: devmap dynamic map-value area based on BTF

2020-06-05 Thread Alexei Starovoitov
On Fri, Jun 5, 2020 at 4:01 AM Toke Høiland-Jørgensen wrote: > > Jesper Dangaard Brouer writes: > > > On Thu, 4 Jun 2020 10:33:41 -0700 > > Alexei Starovoitov wrote: > > > >> On Thu, Jun 04, 2020 at 10:40:06AM -0600, David Ahern wrote: > >> > On 6/4/20 9:48 AM, Jesper Dangaard Brouer wrote: > >>

Re: [PATCH bpf-next V1] bpf: devmap dynamic map-value area based on BTF

2020-06-05 Thread Alexei Starovoitov
On Fri, Jun 5, 2020 at 1:23 AM Jesper Dangaard Brouer wrote: > > Great. If we can remove this requirement of -1 init (and let zero mean > feature isn't used), then I'm all for exposing expose in uapi/bpf.h. Not having it in bpf.h doesn't magically make it invisible. It's uapi because user space C

Re: [PATCH bpf-next V1] bpf: devmap dynamic map-value area based on BTF

2020-06-05 Thread Toke Høiland-Jørgensen
Jesper Dangaard Brouer writes: > On Thu, 4 Jun 2020 10:33:41 -0700 > Alexei Starovoitov wrote: > >> On Thu, Jun 04, 2020 at 10:40:06AM -0600, David Ahern wrote: >> > On 6/4/20 9:48 AM, Jesper Dangaard Brouer wrote: >> > > I will NOT send a patch that expose this in uapi/bpf.h. As I explained

Re: [PATCH bpf-next V1] bpf: devmap dynamic map-value area based on BTF

2020-06-05 Thread Jesper Dangaard Brouer
On Thu, 4 Jun 2020 10:33:41 -0700 Alexei Starovoitov wrote: > On Thu, Jun 04, 2020 at 10:40:06AM -0600, David Ahern wrote: > > On 6/4/20 9:48 AM, Jesper Dangaard Brouer wrote: > > > I will NOT send a patch that expose this in uapi/bpf.h. As I explained > > > before, this caused the issues for

Re: [PATCH bpf-next V1] bpf: devmap dynamic map-value area based on BTF

2020-06-04 Thread Alexei Starovoitov
On Thu, Jun 04, 2020 at 10:40:06AM -0600, David Ahern wrote: > On 6/4/20 9:48 AM, Jesper Dangaard Brouer wrote: > > I will NOT send a patch that expose this in uapi/bpf.h. As I explained > > before, this caused the issues for my userspace application, that > > automatically picked-up struct bpf_de

Re: [PATCH bpf-next V1] bpf: devmap dynamic map-value area based on BTF

2020-06-04 Thread David Ahern
On 6/4/20 9:48 AM, Jesper Dangaard Brouer wrote: > I will NOT send a patch that expose this in uapi/bpf.h. As I explained > before, this caused the issues for my userspace application, that > automatically picked-up struct bpf_devmap_val, and started to fail > (with no code changes), because it ne

Re: [PATCH bpf-next V1] bpf: devmap dynamic map-value area based on BTF

2020-06-04 Thread Jesper Dangaard Brouer
On Wed, 3 Jun 2020 09:22:57 -0700 Alexei Starovoitov wrote: > On Wed, Jun 03, 2020 at 05:44:43PM +0200, Jesper Dangaard Brouer wrote: > > The recent commit fbee97feed9b ("bpf: Add support to attach bpf program to a > > devmap entry"), introduced ability to attach (and run) a separate XDP > > bpf_

Re: [PATCH bpf-next V1] bpf: devmap dynamic map-value area based on BTF

2020-06-03 Thread Alexei Starovoitov
On Wed, Jun 03, 2020 at 05:44:43PM +0200, Jesper Dangaard Brouer wrote: > The recent commit fbee97feed9b ("bpf: Add support to attach bpf program to a > devmap entry"), introduced ability to attach (and run) a separate XDP > bpf_prog for each devmap entry. A bpf_prog is added via a file-descriptor,

[PATCH bpf-next V1] bpf: devmap dynamic map-value area based on BTF

2020-06-03 Thread Jesper Dangaard Brouer
The recent commit fbee97feed9b ("bpf: Add support to attach bpf program to a devmap entry"), introduced ability to attach (and run) a separate XDP bpf_prog for each devmap entry. A bpf_prog is added via a file-descriptor, thus not using the feature requires using value minus-1. The UAPI is extended