Re: [PATCH bpf] xsk: add missing smp_rmb() in xsk_mmap

2019-02-10 Thread Alexei Starovoitov
On Fri, Feb 08, 2019 at 02:13:50PM +0100, Magnus Karlsson wrote: > All the setup code in AF_XDP is protected by a mutex with the > exception of the mmap code that cannot use it. To make sure that a > process banging on the mmap call at the same time as another process > is setting up the socket, sm

[PATCH bpf] xsk: add missing smp_rmb() in xsk_mmap

2019-02-08 Thread Magnus Karlsson
All the setup code in AF_XDP is protected by a mutex with the exception of the mmap code that cannot use it. To make sure that a process banging on the mmap call at the same time as another process is setting up the socket, smp_wmb() calls were added in the umem registration code and the queue crea