HomeFreeBSD

pf: Use counter(9) for pf_state byte/packet tracking

Description

pf: Use counter(9) for pf_state byte/packet tracking

This improves cache behaviour by not writing to the same variable from
multiple cores simultaneously.

pf_state is only used in the kernel, so can be safely modified.

Reviewed by: Lutz Donnerhacke, philip
MFC after: 1 week
Sponsed by: Orange Business Services
Differential Revision: https://reviews.freebsd.org/D27661

(cherry picked from commit 1c00efe98ed7d103b9684ff692ffd5e3b64d0237)

Details

Provenance
kpAuthored on Dec 23 2020, 8:37 AM
Reviewer
philip
Differential Revision
D27661: pf: Use counter_u64 for pf_state byte/packet tracking
Parents
rG4cc87848753d: 81720dba:
Branches
Unknown
Tags
Unknown