bpf: Propagate errors from process_* checks in check_func_arg
authorKumar Kartikeya Dwivedi <memxor@gmail.com>
Wed, 7 Dec 2022 20:41:36 +0000 (02:11 +0530)
committerAlexei Starovoitov <ast@kernel.org>
Fri, 9 Dec 2022 02:25:31 +0000 (18:25 -0800)
commitac50fe51ce873f4299928e312ce2042e35ab5c08
tree28c60cc381b0092d30ee595656bf0fef0adb8b65
parent6b75bd3d036745b9be30917909f03602099adbdb
bpf: Propagate errors from process_* checks in check_func_arg

Currently, we simply ignore the errors in process_spin_lock,
process_timer_func, process_kptr_func, process_dynptr_func. Instead,
bubble up the error by storing and checking err variable.

Acked-by: Joanne Koong <joannelkoong@gmail.com>
Signed-off-by: Kumar Kartikeya Dwivedi <memxor@gmail.com>
Link: https://lore.kernel.org/r/20221207204141.308952-3-memxor@gmail.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
kernel/bpf/verifier.c