]> git.baikalelectronics.ru Git - kernel.git/commit
bpf: remove never-hit branches in verifier adjust_scalar_min_max_vals
authorYonghong Song <yhs@fb.com>
Sun, 29 Apr 2018 05:28:10 +0000 (22:28 -0700)
committerAlexei Starovoitov <ast@kernel.org>
Sun, 29 Apr 2018 15:45:53 +0000 (08:45 -0700)
commit6830ec4f58da93bf1b0821d86bd16afe8e3d0efa
tree42800c7f2cf511669b95fc393d398e0c107eb016
parentfe0de81950c60672d6557d2c927717e840fb8794
bpf: remove never-hit branches in verifier adjust_scalar_min_max_vals

In verifier function adjust_scalar_min_max_vals,
when src_known is false and the opcode is BPF_LSH/BPF_RSH,
early return will happen in the function. So remove
the branch in handling BPF_LSH/BPF_RSH when src_known is false.

Acked-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: Yonghong Song <yhs@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
kernel/bpf/verifier.c