]> git.baikalelectronics.ru Git - kernel.git/commit
bpf: Add bpf_arch_text_poke() helper
authorAlexei Starovoitov <ast@kernel.org>
Thu, 14 Nov 2019 18:57:03 +0000 (10:57 -0800)
committerDaniel Borkmann <daniel@iogearbox.net>
Fri, 15 Nov 2019 22:41:28 +0000 (23:41 +0100)
commit4c2fb64a330ac95ba4e44eb75e2dbc081fdd27b3
tree1c9340853eb72ac070354a5f1291a976ba66911d
parent4b71002f8a495dffe9fb8f00ba0445ef00a5da88
bpf: Add bpf_arch_text_poke() helper

Add bpf_arch_text_poke() helper that is used by BPF trampoline logic to patch
nops/calls in kernel text into calls into BPF trampoline and to patch
calls/nops inside BPF programs too.

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-4-ast@kernel.org
arch/x86/net/bpf_jit_comp.c
include/linux/bpf.h
kernel/bpf/core.c