bpf: adjust insn_aux_data when patching insns
authorAlexei Starovoitov <ast@fb.com>
Thu, 16 Mar 2017 01:26:41 +0000 (18:26 -0700)
committerYves-Alexis Perez <corsac@debian.org>
Thu, 4 Jan 2018 11:12:40 +0000 (11:12 +0000)
commit3ee314288eb26d0e08cf26b821e9f270621b3104
treee66566270ec7761e9fbc2d7a31a4961701055198
parent03a1b3731ba36d81cf6b0c498ce52c364a6bd8c1
bpf: adjust insn_aux_data when patching insns

convert_ctx_accesses() replaces single bpf instruction with a set of
instructions. Adjust corresponding insn_aux_data while patching.
It's needed to make sure subsequent 'for(all insn)' loops
have matching insn and insn_aux_data.

Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: Daniel Borkmann <daniel@iogearbox.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Gbp-Pq: Topic bugfix/all
Gbp-Pq: Name bpf-adjust-insn_aux_data-when-patching-insns.patch
kernel/bpf/verifier.c