mirror of
https://github.com/netdata/libbpf.git
synced 2026-04-07 09:09:06 +08:00
Skip probing for loading
This commit is contained in:
@@ -3330,6 +3330,10 @@ int bpf_map__resize(struct bpf_map *map, __u32 max_entries)
|
|||||||
static int
|
static int
|
||||||
bpf_object__probe_loading(struct bpf_object *obj)
|
bpf_object__probe_loading(struct bpf_object *obj)
|
||||||
{
|
{
|
||||||
|
// Don't probe loading for very old kernels. CentOS 7 can't load this probe.
|
||||||
|
if (obj->kern_version <= KERNEL_VERSION(3, 10, 0))
|
||||||
|
return 0;
|
||||||
|
|
||||||
struct bpf_load_program_attr attr;
|
struct bpf_load_program_attr attr;
|
||||||
char *cp, errmsg[STRERR_BUFSIZE];
|
char *cp, errmsg[STRERR_BUFSIZE];
|
||||||
struct bpf_insn insns[] = {
|
struct bpf_insn insns[] = {
|
||||||
|
|||||||
Reference in New Issue
Block a user