bpf: use BPF_CAST_CALL for casting bpf call
verifier.c uses BPF_CAST_CALL for casting bpf call except at one place in jit_subprogs(). Let's use the macro for consistency. Signed-off-by: Prashant Bhole <bhole_prashant_q7@lab.ntt.co.jp> Acked-by: Song Liu <songliubraving@fb.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org>
This commit is contained in:
parent
725721a650
commit
0d306c31b2
|
@ -7647,9 +7647,8 @@ static int jit_subprogs(struct bpf_verifier_env *env)
|
||||||
insn->src_reg != BPF_PSEUDO_CALL)
|
insn->src_reg != BPF_PSEUDO_CALL)
|
||||||
continue;
|
continue;
|
||||||
subprog = insn->off;
|
subprog = insn->off;
|
||||||
insn->imm = (u64 (*)(u64, u64, u64, u64, u64))
|
insn->imm = BPF_CAST_CALL(func[subprog]->bpf_func) -
|
||||||
func[subprog]->bpf_func -
|
__bpf_call_base;
|
||||||
__bpf_call_base;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* we use the aux data to keep a list of the start addresses
|
/* we use the aux data to keep a list of the start addresses
|
||||||
|
|
Loading…
Reference in New Issue