opnsense-src/sys/netatalk
Robert Watson f93bfb23dc Add internal 'mac_policy_count' counter to the MAC Framework, which is a
count of the number of registered policies.

Rather than unconditionally locking sockets before passing them into MAC,
lock them in the MAC entry points only if mac_policy_count is non-zero.

This avoids locking overhead for a number of socket system calls when no
policies are registered, eliminating measurable overhead for the MAC
Framework for the socket subsystem when there are no active policies.

Possibly socket locks should be acquired by policies if they are required
for socket labels, which would further avoid locking overhead when there
are policies but they don't require labeling of sockets, or possibly
don't even implement socket controls.

Obtained from:	TrustedBSD Project
2009-06-02 18:26:17 +00:00
..
aarp.c Replaced the misleading uses of a historical artefact M_TRYWAIT with M_WAIT. 2008-03-25 09:39:02 +00:00
aarp.h Mark wire data structures in netatalk as __packed so that they are 2007-06-28 12:54:58 +00:00
at.h Cleanup of netatalk atalk layer includes, protocol definitions, and 2007-01-12 13:18:08 +00:00
at_control.c Lock interface address list lock around ifaddr inserts and deletes 2009-04-19 22:01:38 +00:00
at_extern.h Add code to allow the system to handle multiple routing tables. 2008-05-09 23:03:00 +00:00
at_proto.c Add code to allow the system to handle multiple routing tables. 2008-05-09 23:03:00 +00:00
at_rmx.c Cleanup of netatalk atalk layer includes, protocol definitions, and 2007-01-12 13:18:08 +00:00
at_var.h Cleanup of netatalk atalk layer includes, protocol definitions, and 2007-01-12 13:18:08 +00:00
COPYRIGHT Break out my copyrights with our 2-clause BSD license from the UMich 2007-01-08 17:58:27 +00:00
ddp.h Mark wire data structures in netatalk as __packed so that they are 2007-06-28 12:54:58 +00:00
ddp_input.c Add internal 'mac_policy_count' counter to the MAC Framework, which is a 2009-06-02 18:26:17 +00:00
ddp_output.c Annotate two possible bugs in a comment: (1) we allocate and explicitly 2007-11-20 18:50:54 +00:00
ddp_pcb.c Retire the MALLOC and FREE macros. They are an abomination unto style(9). 2008-10-23 15:53:51 +00:00
ddp_pcb.h Clean up DDP layer netatalk code: 2007-01-12 15:07:51 +00:00
ddp_usrreq.c Reimplement the netisr framework in order to support parallel netisr 2009-06-01 10:41:38 +00:00
ddp_var.h Clean up DDP layer netatalk code: 2007-01-12 15:07:51 +00:00
endian.h /* -> /*- for license, minor formatting changes, insert COPYRIGHT into files 2005-01-07 02:35:34 +00:00
phase2.h /* -> /*- for license, minor formatting changes, insert COPYRIGHT into files 2005-01-07 02:35:34 +00:00