Searched refs:ehdr (Results 1 – 4 of 4) sorted by relevance
/scripts/ |
D | recordmcount.h | 211 static unsigned int get_shnum(Elf_Ehdr const *ehdr, Elf_Shdr const *shdr0) in get_shnum() argument 213 if (shdr0 && !ehdr->e_shnum) in get_shnum() 216 return w2(ehdr->e_shnum); in get_shnum() 219 static void set_shnum(Elf_Ehdr *ehdr, Elf_Shdr *shdr0, unsigned int new_shnum) in set_shnum() argument 222 ehdr->e_shnum = 0; in set_shnum() 225 ehdr->e_shnum = w2(new_shnum); in set_shnum() 228 static int get_shstrndx(Elf_Ehdr const *ehdr, Elf_Shdr const *shdr0) in get_shstrndx() argument 230 if (ehdr->e_shstrndx != SHN_XINDEX) in get_shstrndx() 231 return w2(ehdr->e_shstrndx); in get_shstrndx() 236 static void find_symtab(Elf_Ehdr *const ehdr, Elf_Shdr const *shdr0, in find_symtab() argument [all …]
|
D | sorttable.c | 271 Elf32_Ehdr *ehdr = addr; in do_file() local 274 switch (ehdr->e_ident[EI_DATA]) { in do_file() 293 ehdr->e_ident[EI_DATA], fname); in do_file() 297 if (memcmp(ELFMAG, ehdr->e_ident, SELFMAG) != 0 || in do_file() 298 (r2(&ehdr->e_type) != ET_EXEC && r2(&ehdr->e_type) != ET_DYN) || in do_file() 299 ehdr->e_ident[EI_VERSION] != EV_CURRENT) { in do_file() 304 switch (r2(&ehdr->e_machine)) { in do_file() 327 r2(&ehdr->e_machine), fname); in do_file() 331 switch (ehdr->e_ident[EI_CLASS]) { in do_file() 333 if (r2(&ehdr->e_ehsize) != sizeof(Elf32_Ehdr) || in do_file() [all …]
|
D | sorttable.h | 205 Elf_Ehdr *ehdr; member 218 unsigned char *start_loc = (void *)emloc->ehdr + offset; in sort_mcount_loc() 261 static int do_sort(Elf_Ehdr *ehdr, in do_sort() argument 266 Elf_Shdr *s, *shdr = (Elf_Shdr *)((char *)ehdr + _r(&ehdr->e_shoff)); in do_sort() 297 shstrndx = r2(&ehdr->e_shstrndx); in do_sort() 300 secstrings = (const char *)ehdr + _r(&shdr[shstrndx].sh_offset); in do_sort() 302 shnum = r2(&ehdr->e_shnum); in do_sort() 320 relocs = (void *)ehdr + _r(&s->sh_offset); in do_sort() 324 symtab_shndx = (Elf32_Word *)((const char *)ehdr + in do_sort() 331 mstruct.ehdr = ehdr; in do_sort() [all …]
|
D | recordmcount.c | 484 Elf32_Ehdr *ehdr; in do_file() local 487 ehdr = mmap_file(fname); in do_file() 488 if (!ehdr) in do_file() 494 switch (ehdr->e_ident[EI_DATA]) { in do_file() 498 ehdr->e_ident[EI_DATA], fname); in do_file() 527 if (memcmp(ELFMAG, ehdr->e_ident, SELFMAG) != 0 || in do_file() 528 w2(ehdr->e_type) != ET_REL || in do_file() 529 ehdr->e_ident[EI_VERSION] != EV_CURRENT) { in do_file() 535 switch (w2(ehdr->e_machine)) { in do_file() 538 w2(ehdr->e_machine), fname); in do_file() [all …]
|