Re: [PATCH net-next] fix unsafe set_memory_rw from softirq

2013-10-03 Thread Alexei Starovoitov
On Wed, Oct 2, 2013 at 9:57 PM, Eric Dumazet wrote: > On Wed, 2013-10-02 at 21:53 -0700, Eric Dumazet wrote: >> On Wed, 2013-10-02 at 21:44 -0700, Alexei Starovoitov wrote: >> >> > I think ifdef config_x86 is a bit ugly inside struct sk_filter, but >> > don't mind whichever way. >> >> Its not fair

Re: [PATCH net-next] fix unsafe set_memory_rw from softirq

2013-10-02 Thread Eric Dumazet
On Wed, 2013-10-02 at 21:53 -0700, Eric Dumazet wrote: > On Wed, 2013-10-02 at 21:44 -0700, Alexei Starovoitov wrote: > > > I think ifdef config_x86 is a bit ugly inside struct sk_filter, but > > don't mind whichever way. > > Its not fair to make sk_filter bigger, because it means that simple (no

Re: [PATCH net-next] fix unsafe set_memory_rw from softirq

2013-10-02 Thread Eric Dumazet
On Wed, 2013-10-02 at 21:44 -0700, Alexei Starovoitov wrote: > I think ifdef config_x86 is a bit ugly inside struct sk_filter, but > don't mind whichever way. Its not fair to make sk_filter bigger, because it means that simple (non JIT) filter might need an extra cache line. You could presumably

Re: [PATCH net-next] fix unsafe set_memory_rw from softirq

2013-10-02 Thread Alexei Starovoitov
On Wed, Oct 2, 2013 at 9:23 PM, Eric Dumazet wrote: > On Wed, 2013-10-02 at 20:50 -0700, Alexei Starovoitov wrote: >> on x86 system with net.core.bpf_jit_enable = 1 > >> diff --git a/include/linux/filter.h b/include/linux/filter.h >> index a6ac848..378fa03 100644 >> --- a/include/linux/filter.h >>

Re: [PATCH net-next] fix unsafe set_memory_rw from softirq

2013-10-02 Thread Eric Dumazet
On Wed, 2013-10-02 at 20:50 -0700, Alexei Starovoitov wrote: > on x86 system with net.core.bpf_jit_enable = 1 > diff --git a/include/linux/filter.h b/include/linux/filter.h > index a6ac848..378fa03 100644 > --- a/include/linux/filter.h > +++ b/include/linux/filter.h > @@ -27,6 +27,7 @@ struct sk_f