diff options
author | Andrii Nakryiko <andriin@fb.com> | 2020-07-31 21:28:27 +0300 |
---|---|---|
committer | Alexei Starovoitov <ast@kernel.org> | 2020-08-02 06:38:28 +0300 |
commit | 2e49527e52486dac910460b1b3f6fce6e21c6b48 (patch) | |
tree | 49e845274097de42bf2d254945120233936f196a /tools/lib/bpf/bpf.h | |
parent | 73b11c2ab072d5b0599d1e12cc126f55ee306daf (diff) | |
download | linux-2e49527e52486dac910460b1b3f6fce6e21c6b48.tar.xz |
libbpf: Add bpf_link detach APIs
Add low-level bpf_link_detach() API. Also add higher-level bpf_link__detach()
one.
Signed-off-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Acked-by: Song Liu <songliubraving@fb.com>
Acked-by: John Fastabend <john.fastabend@gmail.com>
Link: https://lore.kernel.org/bpf/20200731182830.286260-3-andriin@fb.com
Diffstat (limited to 'tools/lib/bpf/bpf.h')
-rw-r--r-- | tools/lib/bpf/bpf.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tools/lib/bpf/bpf.h b/tools/lib/bpf/bpf.h index 6d367e01d05e..28855fd5b5f4 100644 --- a/tools/lib/bpf/bpf.h +++ b/tools/lib/bpf/bpf.h @@ -178,6 +178,8 @@ LIBBPF_API int bpf_link_create(int prog_fd, int target_fd, enum bpf_attach_type attach_type, const struct bpf_link_create_opts *opts); +LIBBPF_API int bpf_link_detach(int link_fd); + struct bpf_link_update_opts { size_t sz; /* size of this struct for forward/backward compatibility */ __u32 flags; /* extra flags */ |