Discussion:
[Bug 143622] [pfil] [patch] unlock pfil lock while calling firewall hooks
(too old to reply)
b***@freebsd.org
2018-11-06 14:19:26 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=143622

Eugene Grosbein <***@freebsd.org> changed:

What |Removed |Added
----------------------------------------------------------------------------
Status|Open |Closed
Resolution|--- |Feedback Timeout
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freebsd.org
2018-11-08 22:51:57 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=143622

Kristof Provost <***@freebsd.org> changed:

What |Removed |Added
----------------------------------------------------------------------------
CC| |***@freebsd.org

--- Comment #5 from Kristof Provost <***@freebsd.org> ---
(In reply to Max Laier from comment #2)
While rmlocks are relatively lightweight there is still a non-zero overhead.
For the purposes of a test the lock can simply be removed, and without it I see
~2% more packets per second in pf than with it.
I've been thinking about replacing it with a CK_LIST and epoch based cleanup,
but I stopped working on it when I spotted that ipfw relies on the lock. It
should be possible to move that into ipfw, but I'm not sure the 2% is worth
that work.
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freebsd.org
2018-11-09 16:47:31 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=143622

--- Comment #6 from Andrey V. Elsukov <***@FreeBSD.org> ---
(In reply to Kristof Provost from comment #5)
Post by b***@freebsd.org
(In reply to Max Laier from comment #2)
While rmlocks are relatively lightweight there is still a non-zero overhead.
For the purposes of a test the lock can simply be removed, and without it I
see ~2% more packets per second in pf than with it.
I've been thinking about replacing it with a CK_LIST and epoch based
cleanup, but I stopped working on it when I spotted that ipfw relies on the
lock. It should be possible to move that into ipfw, but I'm not sure the 2%
is worth that work.
You can try to revert/rework this change and move IPFW_PF_RLOCK() back to the
ipfw, and then you will be able to change pfil interface locking.

https://svnweb.freebsd.org/base/head/sys/netpfil/ipfw/ip_fw_private.h?r1=314716&r2=316461
--
You are receiving this mail because:
You are the assignee for the bug.
b***@freebsd.org
2018-11-09 18:12:06 UTC
Permalink
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=143622

--- Comment #7 from Gleb Smirnoff <***@FreeBSD.org> ---
Hi!

I now got a work in progress with pfil, and one of the things I do is
converting the synchronization to CK/epoch. For ipfw we will probably revert
back to old internal locking. ae@ says it requires just changing macros.
--
You are receiving this mail because:
You are the assignee for the bug.
Loading...