From c9364a464803dee7c57da611a17d01b57b53ff7d Mon Sep 17 00:00:00 2001 From: Paul Chaignon Date: Tue, 17 Sep 2019 11:41:26 +0200 Subject: sys/linux: support for loopkup-free map value accesses A new BPF instruction that allows lookup-free map value accesses was added in Linux v5.2, with commit d8eca5b ("bpf: implement lookup-free direct value access for maps"). It enables direct access to map values without having to call a BPF helper. It is currently used to implement global variable support. This commit adds support for that new instruction. Signed-off-by: Paul Chaignon --- sys/linux/bpf_amd64.const | 1 + 1 file changed, 1 insertion(+) (limited to 'sys/linux/bpf_amd64.const') diff --git a/sys/linux/bpf_amd64.const b/sys/linux/bpf_amd64.const index ceca22509..5dc99bcc3 100644 --- a/sys/linux/bpf_amd64.const +++ b/sys/linux/bpf_amd64.const @@ -149,6 +149,7 @@ BPF_PROG_TYPE_SOCK_OPS = 13 BPF_PROG_TYPE_TRACEPOINT = 5 BPF_PROG_TYPE_XDP = 6 BPF_PSEUDO_MAP_FD = 1 +BPF_PSEUDO_MAP_VALUE = 2 BPF_RAW_TRACEPOINT_OPEN = 17 BPF_REG_0 = 0 BPF_REG_1 = 1 -- cgit mrf-deployment