netfilter: reduce hook sizes in struct net
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest4 patches 4 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | netfilter: reduce size of hook entry point locationsinclude/ include/ net/ +2 more | +77 | 0 replies | |
| 2/4 | netfilter: add BUILD_BUG_ON asserts for hook array sizesinclude/ | +5 | 3 replies | |
| 3/4 | netfilter: reduce hook array sizes to what is neededinclude/ include/ | +6 | 0 replies | |
| 4/4 | netfilter: add ifdefs to avoid memory waste if family is not supportedinclude/ include/ net/ | +24 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH nf-next 0/4] netfilter: reduce hook sizes in struct net
struct net contains:
struct nf_hook_entries __rcu *hooks[NFPROTO_NUMPROTO][NF_MAX_HOOKS];
which store the hook entry point locations for the various protocol families and the hooks.
This can be compacted a lot by only storing the families and hooks that are actually implemented.
struct net before:
/* size: 5184, cachelines: 81, members: 46 */
after:
/* size: 4544, cachelines: 71, members: 46 */
In case this is too late just ignore this thing, I will resubmit once next opens again.