Re: pfsync: start without kernel lock

2020-08-09 Thread Vitaliy Makkoveev
On Sun, Aug 09, 2020 at 08:53:04PM +0200, Klemens Nanni wrote: > On Sun, Aug 09, 2020 at 06:42:07PM +0300, Vitaliy Makkoveev wrote: > > Does `IFXF_MPSAFE' bit assume that pfsyncioctl() should not rely to > > kernel lock and pfsync(4) related data structures already have their own > > protection? >

Re: pfsync: start without kernel lock

2020-08-09 Thread Klemens Nanni
On Sun, Aug 09, 2020 at 06:42:07PM +0300, Vitaliy Makkoveev wrote: > Does `IFXF_MPSAFE' bit assume that pfsyncioctl() should not rely to > kernel lock and pfsync(4) related data structures already have their own > protection? I say it does not. There's PF_LOCK(), but it a) has to be enabled manual

Re: pfsync: start without kernel lock

2020-08-09 Thread Vitaliy Makkoveev
On Sun, Aug 09, 2020 at 02:33:01PM +0200, Klemens Nanni wrote: > mvs's vnet(4) diff reminded me of pfsync(4). > > This works on my my pair of amd64 firewalls. > > Feedback? OK? > Does `IFXF_MPSAFE' bit assume that pfsyncioctl() should not rely to kernel lock and pfsync(4) related data structure

pfsync: start without kernel lock

2020-08-09 Thread Klemens Nanni
mvs's vnet(4) diff reminded me of pfsync(4). This works on my my pair of amd64 firewalls. Feedback? OK? Index: if_pfsync.c === RCS file: /cvs/src/sys/net/if_pfsync.c,v retrieving revision 1.275 diff -u -p -r1.275 if_pfsync.c --- if