]> www.infradead.org Git - users/dwmw2/linux.git/commit
bpf: use list_head to track explored states and free list
authorEduard Zingerman <eddyz87@gmail.com>
Sat, 15 Feb 2025 11:03:59 +0000 (03:03 -0800)
committerAlexei Starovoitov <ast@kernel.org>
Wed, 19 Feb 2025 03:22:59 +0000 (19:22 -0800)
commit5564ee3abb2ebece37000662a52eb6607b9c9f7d
treef9302e2a09970a3de427a0fa0ac3b77e7521f2d2
parent590eee4268368cfa05db4d4c5524c86e8d94a0bd
bpf: use list_head to track explored states and free list

The next patch in the set needs the ability to remove individual
states from env->free_list while only holding a pointer to the state.
Which requires env->free_list to be a doubly linked list.
This patch converts env->free_list and struct bpf_verifier_state_list
to use struct list_head for this purpose. The change to
env->explored_states is collateral.

Signed-off-by: Eduard Zingerman <eddyz87@gmail.com>
Link: https://lore.kernel.org/r/20250215110411.3236773-9-eddyz87@gmail.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
include/linux/bpf_verifier.h
kernel/bpf/verifier.c