diff options
author | Florian Westphal <fw@strlen.de> | 2024-02-13 18:23:39 +0300 |
---|---|---|
committer | Florian Westphal <fw@strlen.de> | 2024-02-21 13:57:11 +0300 |
commit | aac14d516c2b575af20b426fa04129a28d45c287 (patch) | |
tree | a0ce20da0fcae4bc752faf4f1bf342f8f8a5ce15 /tools/perf/scripts/python/arm-cs-trace-disasm.py | |
parent | 07ace0bbe03b3d8e85869af1dec5e4087b1d57b8 (diff) | |
download | linux-aac14d516c2b575af20b426fa04129a28d45c287.tar.xz |
netfilter: nft_set_pipapo: shrink data structures
The set uses a mix of 'int', 'unsigned int', and size_t.
The rule count limit is NFT_PIPAPO_RULE0_MAX, which cannot
exceed INT_MAX (a few helpers use 'int' as return type).
Add a compile-time assertion for this.
Replace size_t usage in structs with unsigned int or u8 where
the stored values are smaller.
Replace signed-int arguments for lengths with 'unsigned int'
where possible.
Last, remove lt_aligned member: its set but never read.
struct nft_pipapo_match 40 bytes -> 32 bytes
struct nft_pipapo_field 56 bytes -> 32 bytes
Reviewed-by: Stefano Brivio <sbrivio@redhat.com>
Signed-off-by: Florian Westphal <fw@strlen.de>
Diffstat (limited to 'tools/perf/scripts/python/arm-cs-trace-disasm.py')
0 files changed, 0 insertions, 0 deletions