mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-31 16:38:12 +00:00
fe48230cf2
Add selftest validating all the attachment logic around BPF XDP link. Test also link updates and get_obj_info() APIs. Signed-off-by: Andrii Nakryiko <andriin@fb.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org> Link: https://lore.kernel.org/bpf/20200722064603.3350758-9-andriin@fb.com
12 lines
233 B
C
12 lines
233 B
C
// SPDX-License-Identifier: GPL-2.0
|
|
/* Copyright (c) 2020 Facebook */
|
|
#include <linux/bpf.h>
|
|
#include <bpf/bpf_helpers.h>
|
|
|
|
char LICENSE[] SEC("license") = "GPL";
|
|
|
|
SEC("xdp/handler")
|
|
int xdp_handler(struct xdp_md *xdp)
|
|
{
|
|
return 0;
|
|
}
|