Re: [PATCH bpf-next v3] bpf: bpf_{g,s}etsockopt for struct bpf_sock_addr

2020-05-01 Thread Andrey Ignatov
Stanislav Fomichev [Fri, 2020-05-01 15:07 -0700]: > On Fri, May 1, 2020 at 2:52 PM Andrey Ignatov wrote: > > > > Stanislav Fomichev [Thu, 2020-04-30 16:32 -0700]: > > > Currently, bpf_getsockopt and bpf_setsockopt helpers operate on the > > > 'struct bpf_sock_ops' context in BPF_PROG_TYPE_SOCK_O

Re: [PATCH bpf-next v3] bpf: bpf_{g,s}etsockopt for struct bpf_sock_addr

2020-05-01 Thread Andrey Ignatov
Stanislav Fomichev [Thu, 2020-04-30 16:32 -0700]: > Currently, bpf_getsockopt and bpf_setsockopt helpers operate on the > 'struct bpf_sock_ops' context in BPF_PROG_TYPE_SOCK_OPS program. > Let's generalize them and make them available for 'struct bpf_sock_addr'. > That way, in the future, we can a

Re: [PATCH bpf-next v3] bpf: bpf_{g,s}etsockopt for struct bpf_sock_addr

2020-05-01 Thread Alexei Starovoitov
On Fri, May 1, 2020 at 11:33 AM John Fastabend wrote: > > Stanislav Fomichev wrote: > > Currently, bpf_getsockopt and bpf_setsockopt helpers operate on the > > 'struct bpf_sock_ops' context in BPF_PROG_TYPE_SOCK_OPS program. > > Let's generalize them and make them available for 'struct bpf_sock_ad

RE: [PATCH bpf-next v3] bpf: bpf_{g,s}etsockopt for struct bpf_sock_addr

2020-05-01 Thread John Fastabend
Stanislav Fomichev wrote: > Currently, bpf_getsockopt and bpf_setsockopt helpers operate on the > 'struct bpf_sock_ops' context in BPF_PROG_TYPE_SOCK_OPS program. > Let's generalize them and make them available for 'struct bpf_sock_addr'. > That way, in the future, we can allow those helpers in mor

Re: [PATCH bpf-next v3] bpf: bpf_{g,s}etsockopt for struct bpf_sock_addr

2020-04-30 Thread Martin KaFai Lau
On Thu, Apr 30, 2020 at 04:31:52PM -0700, Stanislav Fomichev wrote: > Currently, bpf_getsockopt and bpf_setsockopt helpers operate on the > 'struct bpf_sock_ops' context in BPF_PROG_TYPE_SOCK_OPS program. > Let's generalize them and make them available for 'struct bpf_sock_addr'. > That way, in the