tools/testing/selftests/bpf/progs/fentry_test.c

Source file repositories/reference/linux-study-clean/tools/testing/selftests/bpf/progs/fentry_test.c

File Facts

System
Linux kernel
Corpus path
tools/testing/selftests/bpf/progs/fentry_test.c
Extension
.c
Size
1630 bytes
Lines
80
Domain
Support Tooling And Documentation
Bucket
tools
Inferred role
Support Tooling And Documentation: implementation source
Status
source implementation candidate

Why This File Exists

Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.

Dependency Surface

Detected Declarations

Annotated Snippet

struct bpf_fentry_test_t {
	struct bpf_fentry_test_t *a;
};

__u64 test7_result = 0;
SEC("fentry/bpf_fentry_test7")
int BPF_PROG(test7, struct bpf_fentry_test_t *arg)
{
	if (!arg)
		test7_result = 1;
	return 0;
}

__u64 test8_result = 0;
SEC("fentry/bpf_fentry_test8")
int BPF_PROG(test8, struct bpf_fentry_test_t *arg)
{
	if (arg->a == 0)
		test8_result = 1;
	return 0;
}

Annotation

Implementation Notes