blob: 1800e7b7afe2d8f31907f1ffffb582b7d30d1656 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
// SPDX-License-Identifier: GPL-2.0
/* Copyright (c) 2026 Meta Platforms, Inc. and affiliates. */
#include <vmlinux.h>
#include <bpf/bpf_helpers.h>
long stack_g, stack_h, stack_ret;
SEC("fentry/callee_stack")
int stack_entry(unsigned long long *ctx)
{
stack_g = ctx[6];
stack_h = ctx[7];
return 0;
}
SEC("fexit/callee_stack")
int stack_exit(unsigned long long *ctx)
{
stack_ret = ctx[8];
return 0;
}
char _license[] SEC("license") = "GPL";
|