Re: [RPC PATCH bpf-next] bpf: implement new BPF_CGROUP_INET_SOCK_POST_CONNECT

2021-01-15 Thread Yonghong Song
On 1/15/21 8:39 AM, Stanislav Fomichev wrote: On Thu, Jan 14, 2021 at 8:27 PM Yonghong Song wrote: On 1/14/21 7:59 PM, Alexei Starovoitov wrote: On Thu, Jan 14, 2021 at 7:51 PM Stanislav Fomichev wrote: lock_sock(sock->sk); err = __inet_stream_connect(sock, uaddr,

Re: [RPC PATCH bpf-next] bpf: implement new BPF_CGROUP_INET_SOCK_POST_CONNECT

2021-01-15 Thread kernel test robot
Hi Stanislav, Thank you for the patch! Yet something to improve: [auto build test ERROR on bpf-next/master] url: https://github.com/0day-ci/linux/commits/Stanislav-Fomichev/bpf-implement-new-BPF_CGROUP_INET_SOCK_POST_CONNECT/20210115-112524 base: https://git.kernel.org/pub/scm/linux/kernel

Re: [RPC PATCH bpf-next] bpf: implement new BPF_CGROUP_INET_SOCK_POST_CONNECT

2021-01-14 Thread kernel test robot
Hi Stanislav, Thank you for the patch! Yet something to improve: [auto build test ERROR on bpf-next/master] url: https://github.com/0day-ci/linux/commits/Stanislav-Fomichev/bpf-implement-new-BPF_CGROUP_INET_SOCK_POST_CONNECT/20210115-112524 base: https://git.kernel.org/pub/scm/linux/kernel

Re: [RPC PATCH bpf-next] bpf: implement new BPF_CGROUP_INET_SOCK_POST_CONNECT

2021-01-14 Thread Yonghong Song
On 1/14/21 7:59 PM, Alexei Starovoitov wrote: On Thu, Jan 14, 2021 at 7:51 PM Stanislav Fomichev wrote: lock_sock(sock->sk); err = __inet_stream_connect(sock, uaddr, addr_len, flags, 0); Similarly here, attaching fexit to __inet_stream_connect would execute your BPF prog

Re: [RPC PATCH bpf-next] bpf: implement new BPF_CGROUP_INET_SOCK_POST_CONNECT

2021-01-14 Thread Alexei Starovoitov
On Thu, Jan 14, 2021 at 7:51 PM Stanislav Fomichev wrote: > > > > > > lock_sock(sock->sk); > > > err = __inet_stream_connect(sock, uaddr, addr_len, flags, 0); > > > > Similarly here, attaching fexit to __inet_stream_connect would execute > > your BPF program at exactly the same tim

Re: [RPC PATCH bpf-next] bpf: implement new BPF_CGROUP_INET_SOCK_POST_CONNECT

2021-01-14 Thread Andrii Nakryiko
On Thu, Jan 14, 2021 at 4:19 PM Stanislav Fomichev wrote: > > We are playing with doing hybrid conntrack where BPF generates > connect/disconnect/etc events and puts them into perfbuf (or, later, > new ringbuf). We can get most of the functionality out of > existing hooks: > - BPF_CGROUP_SOCK_OPS