]> git.baikalelectronics.ru Git - kernel.git/commit
bpf: inline map in map lookup functions for array and htab
authorDaniel Borkmann <daniel@iogearbox.net>
Sat, 19 Aug 2017 01:12:46 +0000 (03:12 +0200)
committerDavid S. Miller <davem@davemloft.net>
Sun, 20 Aug 2017 04:56:34 +0000 (21:56 -0700)
commitdc2370e63a80d7ca4f92a49aa728d325c57036bc
tree859903eeb8d19cdfeb44fac4c72e594058534a56
parentbf881de40e883a77f21710282fc5df5cc3bbf2f2
bpf: inline map in map lookup functions for array and htab

Avoid two successive functions calls for the map in map lookup, first
is the bpf_map_lookup_elem() helper call, and second the callback via
map->ops->map_lookup_elem() to get to the map in map implementation.
Implementation inlines array and htab flavor for map in map lookups.

Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Acked-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
kernel/bpf/arraymap.c
kernel/bpf/hashtab.c