diff options
author | Jakub Kicinski <jakub.kicinski@netronome.com> | 2018-07-10 14:43:06 -0700 |
---|---|---|
committer | Daniel Borkmann <daniel@iogearbox.net> | 2018-07-11 22:13:34 +0200 |
commit | 26736eb9a483715c2e971a8866f55fbb156903e2 (patch) | |
tree | 96dd4d1be8727b4b43c530bbf77f294bfd72fc1a /tools/bpf/bpftool/Documentation | |
parent | 531b014e7a2fedaeff0b19b2934d830cd4b35dc0 (diff) | |
download | linux-26736eb9a483715c2e971a8866f55fbb156903e2.tar.bz2 |
tools: libbpf: allow map reuse
More advanced applications may want to only replace programs without
destroying associated maps. Allow libbpf users to achieve that.
Instead of always creating all of the maps at load time, expose to
users an API to reconstruct the map object from already existing
map.
The map parameters are read from the kernel and replace the parameters
of the ELF map. libbpf does not restrict the map replacement, i.e.
the reused map does not have to be compatible with the ELF map
definition. We relay on the verifier for checking the compatibility
between maps and programs. The ELF map definition is completely
overwritten by the information read from the kernel, to make sure
libbpf's view of map object corresponds to the actual map.
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Reviewed-by: Quentin Monnet <quentin.monnet@netronome.com>
Acked-by: Andrey Ignatov <rdna@fb.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Diffstat (limited to 'tools/bpf/bpftool/Documentation')
0 files changed, 0 insertions, 0 deletions