- moving state look up outside of PF_LOCK()
authorsashan <sashan@openbsd.org>
Tue, 11 Sep 2018 07:53:38 +0000 (07:53 +0000)
committersashan <sashan@openbsd.org>
Tue, 11 Sep 2018 07:53:38 +0000 (07:53 +0000)
commitddb22b9530d7ad1b4698803d7b6dcb21c96a3f7d
tree442ace36d324484a08a4b322d19b0fdd80c176c0
parente352df4c1c1d0ed1e78200e7440a13d0347b6dc5
- moving state look up outside of PF_LOCK()

this change adds a pf_state_lock rw-lock, which protects consistency
of state table in PF. The code delivered in this change is guarded
by 'WITH_PF_LOCK', which is still undefined. People, who are willing
to experiment and want to run it must do two things:

- compile kernel with -DWITH_PF_LOCK
- bump NET_TASKQ from 1 to ... sky is the limit,
  (just select some sensible value for number of tasks your
  system is able to handle)

OK bluhm@
sys/net/if_pfsync.c
sys/net/if_pfsync.h
sys/net/pf.c
sys/net/pf_ioctl.c
sys/net/pfvar.h
sys/net/pfvar_priv.h