Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

at master 22 lines 684 B view raw
1// SPDX-License-Identifier: GPL-2.0 2/* Copyright (c) 2024 Meta Platforms, Inc. and affiliates. */ 3#include <vmlinux.h> 4#include <bpf/bpf_helpers.h> 5#include "../test_kmods/bpf_testmod.h" 6 7char _license[] SEC("license") = "GPL"; 8 9/* 10 * This subprogram validates that libbpf handles the situation in which BPF 11 * object has subprograms in .text section, but has no entry BPF programs. 12 * At some point that was causing issues due to legacy logic of treating such 13 * subprogram as entry program (with unknown program type, which would fail). 14 */ 15int dangling_subprog(void) 16{ 17 /* do nothing, just be here */ 18 return 0; 19} 20 21SEC(".struct_ops.link") 22struct bpf_testmod_ops testmod_do_detach;