Re: svn commit: r348303 - head/sys/net

2019-05-29 Thread Gleb Smirnoff
On Wed, May 29, 2019 at 08:56:23PM +0300, Andrey V. Elsukov wrote: A> On 29.05.2019 06:12, Gleb Smirnoff wrote: A> > A> bpf_mtap() is not the only consumer of bd_bif, some of them expect it A> > A> becomes NULL when descriptor is detached. A> > A> > May be then make a flag attached/detached? A> A

Re: svn commit: r348303 - head/sys/net

2019-05-29 Thread Andrey V. Elsukov
On 29.05.2019 06:12, Gleb Smirnoff wrote: > A> bpf_mtap() is not the only consumer of bd_bif, some of them expect it > A> becomes NULL when descriptor is detached. > > May be then make a flag attached/detached? Do you have benchmark results that show some benefits in performance? :) I prefer to w

Re: svn commit: r348303 - head/sys/net

2019-05-28 Thread Gleb Smirnoff
On Wed, May 29, 2019 at 03:23:23AM +0300, Andrey V. Elsukov wrote: A> > --- a/FreeBSD/sys/net/bpf.c A> > +++ b/FreeBSD/sys/net/bpf.c A> > @@ -857,7 +857,6 @@ bpf_detachd_locked(struct bpf_d *d, bool detached_ifp) A> > /* Save bd_writer value */ A> > error = d->bd_writer; A> >

Re: svn commit: r348303 - head/sys/net

2019-05-28 Thread Andrey V. Elsukov
29.05.2019 3:10, Gleb Smirnoff пишет: > Hi Andrey, > > I made a different change to mitigate this panic: don't clear the pointer. > > --- a/FreeBSD/sys/net/bpf.c > +++ b/FreeBSD/sys/net/bpf.c > @@ -857,7 +857,6 @@ bpf_detachd_locked(struct bpf_d *d, bool detached_ifp) > /* Save bd_write

Re: svn commit: r348303 - head/sys/net

2019-05-28 Thread Gleb Smirnoff
Hi Andrey, I made a different change to mitigate this panic: don't clear the pointer. --- a/FreeBSD/sys/net/bpf.c +++ b/FreeBSD/sys/net/bpf.c @@ -857,7 +857,6 @@ bpf_detachd_locked(struct bpf_d *d, bool detached_ifp) /* Save bd_writer value */ error = d->bd_writer; ifp =