bpf, test_run: Remove unnecessary prog type checks
authorDaniel Xu <dxu@dxuuu.xyz>
Sun, 29 May 2022 20:15:41 +0000 (15:15 -0500)
committerAndrii Nakryiko <andrii@kernel.org>
Fri, 3 Jun 2022 21:53:33 +0000 (14:53 -0700)
commit988d0d5899248b758d2f2eae3b57708fe78a8618
tree2cbc6fb9418bf13e78f3b41f97f847fdf4f7f740
parent9bbdfad8a5192cfa698994dd8db3a52b137e7478
bpf, test_run: Remove unnecessary prog type checks

These checks were effectively noops b/c there's only one way these
functions get called: through prog_ops dispatching. And since there's no
other callers, we can be sure that `prog` is always the correct type.

Signed-off-by: Daniel Xu <dxu@dxuuu.xyz>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Acked-by: Song Liu <songliubraving@fb.com>
Link: https://lore.kernel.org/bpf/0a9aaac329f76ddb17df1786b001117823ffefa5.1653855302.git.dxu@dxuuu.xyz
net/bpf/test_run.c