Lines Matching refs:shname
170 static int get_sec(Elf *elf, int i, GElf_Ehdr *ehdr, char **shname, in get_sec() argument
182 *shname = elf_strptr(elf, ehdr->e_shstrndx, shdr->sh_name); in get_sec()
183 if (!*shname || !shdr->sh_size) in get_sec()
230 char *shname, *shname_prog; in load_bpf_file() local
253 if (get_sec(elf, i, &ehdr, &shname, &shdr, &data)) in load_bpf_file()
258 i, shname, data->d_buf, data->d_size, in load_bpf_file()
261 if (strcmp(shname, "license") == 0) { in load_bpf_file()
264 } else if (strcmp(shname, "version") == 0) { in load_bpf_file()
272 } else if (strcmp(shname, "maps") == 0) { in load_bpf_file()
284 if (get_sec(elf, i, &ehdr, &shname, &shdr, &data)) in load_bpf_file()
314 if (get_sec(elf, i, &ehdr, &shname, &shdr, &data)) in load_bpf_file()
317 if (memcmp(shname, "kprobe/", 7) == 0 || in load_bpf_file()
318 memcmp(shname, "kretprobe/", 10) == 0 || in load_bpf_file()
319 memcmp(shname, "socket", 6) == 0) in load_bpf_file()
320 load_and_attach(shname, data->d_buf, data->d_size); in load_bpf_file()