HomeFreeBSD

pf: reduce number of hashing operations when handling source nodes

Description

pf: reduce number of hashing operations when handling source nodes

Reduce number of hashing operations when handling source nodes by always
having a pointer to the hash row mutex in the source node. Provide
macros for handling and asserting the mutex. Calculate the hash only
once in pf_find_src_node() and then use this hash in subsequent
operations.

Cherry-picked from development of D39880

Reviewed by: kp, mjg
Sponsored by: InnoGames GmbH
Differential Revision: https://reviews.freebsd.org/D39888

Details

Provenance
vegeta_tuxpowered.netAuthored on May 1 2023, 2:07 PM
kpCommitted on May 1 2023, 2:15 PM
Reviewer
kp
Differential Revision
D39888: pf :Reduce number of hashing operations when handling source nodes
Parents
rG6a09a7f1e9a5: netlink: always zero provided header buffers.
Branches
Unknown
Tags
Unknown