bpf: Refactor x86 JIT into helpers
authorAlexei Starovoitov <ast@kernel.org>
Thu, 14 Nov 2019 18:57:02 +0000 (10:57 -0800)
committerDaniel Borkmann <daniel@iogearbox.net>
Fri, 15 Nov 2019 22:41:06 +0000 (23:41 +0100)
commit3b2744e665206ea82ce7673cb3ec889b2898a267
treec8addb85c766659e36da4ef6fe2566430c057256
parentc3d6324f841bab2403be6419986e2b1d1068d423
bpf: Refactor x86 JIT into helpers

Refactor x86 JITing of LDX, STX, CALL instructions into separate helper
functions.  No functional changes in LDX and STX helpers.  There is a minor
change in CALL helper. It will populate target address correctly on the first
pass of JIT instead of second pass. That won't reduce total number of JIT
passes though.

Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Song Liu <songliubraving@fb.com>
Acked-by: Andrii Nakryiko <andriin@fb.com>
Link: https://lore.kernel.org/bpf/20191114185720.1641606-3-ast@kernel.org
arch/x86/net/bpf_jit_comp.c