Lines Matching refs:shname
137 static int get_sec(Elf *elf, int i, GElf_Ehdr *ehdr, char **shname, in get_sec() argument
149 *shname = elf_strptr(elf, ehdr->e_shstrndx, shdr->sh_name); in get_sec()
150 if (!*shname || !shdr->sh_size) in get_sec()
197 char *shname, *shname_prog; in load_bpf_file() local
220 if (get_sec(elf, i, &ehdr, &shname, &shdr, &data)) in load_bpf_file()
225 i, shname, data->d_buf, data->d_size, in load_bpf_file()
228 if (strcmp(shname, "license") == 0) { in load_bpf_file()
231 } else if (strcmp(shname, "version") == 0) { in load_bpf_file()
239 } else if (strcmp(shname, "maps") == 0) { in load_bpf_file()
251 if (get_sec(elf, i, &ehdr, &shname, &shdr, &data)) in load_bpf_file()
281 if (get_sec(elf, i, &ehdr, &shname, &shdr, &data)) in load_bpf_file()
284 if (memcmp(shname, "kprobe/", 7) == 0 || in load_bpf_file()
285 memcmp(shname, "kretprobe/", 10) == 0 || in load_bpf_file()
286 memcmp(shname, "socket", 6) == 0) in load_bpf_file()
287 load_and_attach(shname, data->d_buf, data->d_size); in load_bpf_file()