Thread (14 messages) 14 messages, 4 authors, 2020-01-22

Re: [PATCH v2 bpf-next 3/7] bpf: Introduce function-by-function verification

From: Alexei Starovoitov <hidden>
Date: 2020-01-22 02:30:21
Also in: bpf

On Thu, Jan 9, 2020 at 2:17 PM Alexei Starovoitov
[off-list ref] wrote:
quoted
quoted
+
+   ret = do_check(env);
+out:
+   if (env->cur_state) {
I think env->cur_state will never be NULL here. This check is necessary
before this patch (when we allocate cur_state in do_check()).
yeah. good catch. 'if' can be dropped. I'll follow up with a clean up patch or
will fold it if respin is necessary for other reasons.
that is the case of code review gone wrong.
This dropped 'if' during code move (because we both felt that it's unnecessary)
is the reason for syzbot panic under fault injection:
https://lore.kernel.org/lkml/00000000000048111c059cab1695@google.com/ (local)
I'm sending a fix for this shortly to restore that 'if' check.
This time adding a comment :)
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help