tmp_suning_uos_patched/kernel/bpf
Toke Høiland-Jørgensen 0cdbb4b09a devmap: Allow map lookups from eBPF
We don't currently allow lookups into a devmap from eBPF, because the map
lookup returns a pointer directly to the dev->ifindex, which shouldn't be
modifiable from eBPF.

However, being able to do lookups in devmaps is useful to know (e.g.)
whether forwarding to a specific interface is enabled. Currently, programs
work around this by keeping a shadow map of another type which indicates
whether a map index is valid.

Since we now have a flag to make maps read-only from the eBPF side, we can
simply lift the lookup restriction if we make sure this flag is always set.

Signed-off-by: Toke Høiland-Jørgensen <toke@redhat.com>
Acked-by: Jonathan Lemon <jonathan.lemon@gmail.com>
Acked-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
2019-06-29 01:31:09 +02:00
..
arraymap.c
bpf_lru_list.c
bpf_lru_list.h
btf.c
cgroup.c bpf: implement getsockopt and setsockopt hooks 2019-06-27 15:25:16 -07:00
core.c bpf: implement getsockopt and setsockopt hooks 2019-06-27 15:25:16 -07:00
cpumap.c devmap/cpumap: Use flush list instead of bitmap 2019-06-29 01:31:08 +02:00
devmap.c devmap: Allow map lookups from eBPF 2019-06-29 01:31:09 +02:00
disasm.c
disasm.h
hashtab.c
helpers.c
inode.c
local_storage.c
lpm_trie.c
Makefile
map_in_map.c
map_in_map.h
offload.c
percpu_freelist.c
percpu_freelist.h
queue_stack_maps.c
reuseport_array.c
stackmap.c
syscall.c bpf: implement getsockopt and setsockopt hooks 2019-06-27 15:25:16 -07:00
tnum.c
verifier.c devmap: Allow map lookups from eBPF 2019-06-29 01:31:09 +02:00
xskmap.c xskmap: Move non-standard list manipulation to helper 2019-06-29 01:31:08 +02:00