bpf: remove redundant REG_LIVE_READ check in stacksafe()
authorEduard Zingerman <eddyz87@gmail.com>
Fri, 19 Sep 2025 02:18:36 +0000 (19:18 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Fri, 19 Sep 2025 16:27:22 +0000 (09:27 -0700)
commit12a23f93a50dad7f820ca4326c7e289e7e13fb9f
tree7f1476cbe41a1a850517cb89c28ec6c21485d28b
parent6cd21eb9adc924237a6f398a7f6c9f3da251df71
bpf: remove redundant REG_LIVE_READ check in stacksafe()

stacksafe() is called in exact == NOT_EXACT mode only for states that
had been porcessed by clean_verifier_states(). The latter replaces
dead stack spills with a series of STACK_INVALID masks. Such masks are
already handled by stacksafe().

Signed-off-by: Eduard Zingerman <eddyz87@gmail.com>
Link: https://lore.kernel.org/r/20250918-callchain-sensitive-liveness-v3-3-c3cd27bacc60@gmail.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
kernel/bpf/verifier.c