kernel_optimize_test/include
Andrii Nakryiko 73b11c2ab0 bpf: Add support for forced LINK_DETACH command
Add LINK_DETACH command to force-detach bpf_link without destroying it. It has
the same behavior as auto-detaching of bpf_link due to cgroup dying for
bpf_cgroup_link or net_device being destroyed for bpf_xdp_link. In such case,
bpf_link is still a valid kernel object, but is defuncts and doesn't hold BPF
program attached to corresponding BPF hook. This functionality allows users
with enough access rights to manually force-detach attached bpf_link without
killing respective owner process.

This patch implements LINK_DETACH for cgroup, xdp, and netns links, mostly
re-using existing link release handling code.

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-2-andriin@fb.com
2020-08-01 20:38:28 -07:00
..
acpi
asm-generic Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2020-07-25 17:49:04 -07:00
clocksource
crypto
drm
dt-bindings
keys
kunit
kvm
linux bpf: Add support for forced LINK_DETACH command 2020-08-01 20:38:28 -07:00
math-emu
media
misc
net bpf, xdp: Remove XDP_QUERY_PROG and XDP_QUERY_PROG_HW XDP commands 2020-07-25 20:37:02 -07:00
pcmcia
ras
rdma
scsi
soc net: mscc: ocelot: extend watermark encoding function 2020-07-13 17:40:02 -07:00
sound ASoC: Fixes for v5.8 2020-07-17 18:19:02 +02:00
target
trace bpf: cpumap: Implement XDP_REDIRECT for eBPF programs attached to map entries 2020-07-16 17:00:32 +02:00
uapi bpf: Add support for forced LINK_DETACH command 2020-08-01 20:38:28 -07:00
vdso
video
xen xen: netif.h: add a new extra type for XDP 2020-07-01 15:25:14 -07:00