bpf: refactor special field-type detection
authorMykyta Yatsenko <yatsenko@meta.com>
Tue, 23 Sep 2025 11:23:56 +0000 (12:23 +0100)
committerAlexei Starovoitov <ast@kernel.org>
Tue, 23 Sep 2025 14:34:38 +0000 (07:34 -0700)
commitf90213261681268b6dc4c944503ddcc20e15f8fe
tree71691dc18f77c19e4e7f4622ef318b4fdc2d5af0
parent58a5820582e4c809dd26b3f2d396cf072411d6e8
bpf: refactor special field-type detection

Reduce code duplication in detection of the known special field types in
map values. This refactoring helps to avoid copying a chunk of code in
the next patch of the series.

Signed-off-by: Mykyta Yatsenko <yatsenko@meta.com>
Acked-by: Eduard Zingerman <eddyz87@gmail.com>
Acked-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/r/20250923112404.668720-2-mykyta.yatsenko5@gmail.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
kernel/bpf/btf.c