bpf: adjust insn_aux_data when patching insns
authorAlexei Starovoitov <ast@fb.com>
Thu, 16 Mar 2017 01:26:41 +0000 (18:26 -0700)
committerDavid S. Miller <davem@davemloft.net>
Fri, 17 Mar 2017 03:44:11 +0000 (20:44 -0700)
commit8041902dae5299c1f194ba42d14383f734631009
treebd1153b0a070c9d8b5d8bb24b11b212bb8421926
parent79741b3bdec01a8628368fbcfccc7d189ed606cb
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>
kernel/bpf/verifier.c