summaryrefslogtreecommitdiff
path: root/lib/raid6/recov_s390xc.c
diff options
context:
space:
mode:
authorStanislav Fomichev <sdf@google.com>2019-02-12 15:42:38 -0800
committerDaniel Borkmann <daniel@iogearbox.net>2019-02-19 00:17:03 +0100
commitdf1a2cb7c74b3d3abc8d8c2d690f82c8ebc3490a (patch)
tree21336c0eca9c46abc9ad23bbd9813663dd120522 /lib/raid6/recov_s390xc.c
parent21d2cb491b9e10bfdf10424673b43cd9eddc2da1 (diff)
bpf/test_run: fix unkillable BPF_PROG_TEST_RUN
Syzbot found out that running BPF_PROG_TEST_RUN with repeat=0xffffffff makes process unkillable. The problem is that when CONFIG_PREEMPT is enabled, we never see need_resched() return true. This is due to the fact that preempt_enable() (which we do in bpf_test_run_one on each iteration) now handles resched if it's needed. Let's disable preemption for the whole run, not per test. In this case we can properly see whether resched is needed. Let's also properly return -EINTR to the userspace in case of a signal interrupt. See recent discussion: http://lore.kernel.org/netdev/CAH3MdRWHr4N8jei8jxDppXjmw-Nw=puNDLbu1dQOFQHxfU2onA@mail.gmail.com I'll follow up with the same fix bpf_prog_test_run_flow_dissector in bpf-next. Reported-by: syzbot <syzkaller@googlegroups.com> Signed-off-by: Stanislav Fomichev <sdf@google.com> Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Diffstat (limited to 'lib/raid6/recov_s390xc.c')
0 files changed, 0 insertions, 0 deletions