/external/elfutils/libelf/ |
H A D | elf_update.c | 30 write_file (Elf *elf, off_t size, int change_bo, size_t shnum) argument 60 ? __elf32_updatemmap (elf, change_bo, shnum) 61 : __elf64_updatemmap (elf, change_bo, shnum)) != 0) 69 ? __elf32_updatefile (elf, change_bo, shnum) 70 : __elf64_updatefile (elf, change_bo, shnum)) != 0) 97 size_t shnum; local 129 shnum = (elf->state.elf.scns_last->cnt == 0 137 ? __elf32_updatenull (elf, &change_bo, shnum) 138 : __elf64_updatenull (elf, &change_bo, shnum)); 165 size = write_file (elf, size, change_bo, shnum); [all...] |
H A D | elf32_updatenull.c | 40 size_t shnum, int *change_bop) 82 if (unlikely (shnum >= SHN_LORESERVE)) 88 update_if_changed (ehdr->e_shnum, shnum, 103 __elfw2(LIBELFBITS,updatenull) (Elf *elf, int *change_bop, size_t shnum) 111 if (ELFW(default_ehdr,LIBELFBITS) (elf, ehdr, shnum, change_bop) != 0) 146 if (shnum > 0) 153 if (shnum >= SHN_LORESERVE) 158 = shnum; 345 + (elf_typesize (LIBELFBITS, ELF_T_SHDR, shnum)))); 363 size += elf_typesize (LIBELFBITS, ELF_T_SHDR, shnum); [all...] |
H A D | elf32_getshdr.c | 60 size_t shnum; local 72 if (INTUSE (elf_getshnum) (elf, &shnum) != 0) 74 size = shnum * sizeof (ElfW2(LIBELFBITS,Shdr)); 114 for (cnt = 0; cnt < shnum; ++cnt) 143 for (cnt = 0; cnt < shnum; ++cnt) 172 for (cnt = 0; cnt < shnum; ++cnt)
|
H A D | libelfP.h | 427 extern off_t __elf32_updatenull (Elf *elf, int *change_bop, size_t shnum) 429 extern off_t __elf64_updatenull (Elf *elf, int *change_bop, size_t shnum) 432 extern int __elf32_updatemmap (Elf *elf, int change_bo, size_t shnum) 434 extern int __elf64_updatemmap (Elf *elf, int change_bo, size_t shnum) 436 extern int __elf32_updatefile (Elf *elf, int change_bo, size_t shnum) 438 extern int __elf64_updatefile (Elf *elf, int change_bo, size_t shnum)
|
H A D | elf32_updatefile.c | 84 __elfw2(LIBELFBITS,updatemmap) (Elf *elf, int change_bo, size_t shnum) 169 if (shnum > 0) 173 Elf_Scn **scns = (Elf_Scn **) alloca (shnum * sizeof (Elf_Scn *)); 193 for (cnt = 0; cnt < shnum; ++cnt) 351 __elfw2(LIBELFBITS,updatefile) (Elf *elf, int change_bo, size_t shnum) 475 if (shnum > 0) 480 Elf_Scn **scns = (Elf_Scn **) alloca (shnum * sizeof (Elf_Scn *)); 494 alloca (shnum * sizeof (ElfW2(LIBELFBITS,Shdr))); 502 for (cnt = 0; cnt < shnum; ++cnt) 611 * shnum, shdr_offse [all...] |
/external/elfutils/libebl/ |
H A D | eblsectionname.c | 24 ebl_section_name (ebl, section, xsection, buf, len, scnnames, shnum) 31 size_t shnum; 49 && (size_t) section < shnum)
|
H A D | libebl.h | 154 const char *scnnames[], size_t shnum);
|
/external/elfcopy/ |
H A D | elfcopy.h | 83 size_t shnum,
|
H A D | elfcopy.c | 117 size_t shnum, 172 shdridx = shnum; 291 has a section number equal to shnum--hence the ASSERT(). 293 ASSERT(!rebuild_shstrtab || shdr_info[cnt].data || cnt < shnum); 434 sym->st_shndx == SHN_UNDEF || sym->st_shndx >= shnum || 443 sym->st_shndx >= shnum) 687 for (cnt = 1; cnt < shnum; ++cnt) { 729 shdr_info, shnum, 854 } /* for (cnt = 1; cnt < shnum; ++cnt) */ 2232 size_t shnum; local 109 adjust_elf(Elf *elf, const char *elf_name, Elf *newelf, const char *newelf_name __attribute__((unused)), Ebl *ebl, GElf_Ehdr *ehdr, bool *sym_filter, int num_symbols, struct shdr_info_t *shdr_info, int shdr_info_len, GElf_Phdr *phdr_info, size_t highest_scn_num, size_t shnum, size_t shstrndx, struct Ebl_Strtab *shst, bool sections_dropped_or_rearranged, int dynamic_idx, int dynsym_idx, int shady, Elf_Data **shstrtab_data, bool adjust_alloc_section_offsets, bool rebuild_shstrtab) argument [all...] |
/external/elfutils/src/ |
H A D | strip.c | 375 size_t shnum; local 528 if (unlikely (elf_getshnum (elf, &shnum) < 0)) 539 if ((shnum + 2) * sizeof (struct shdr_info) > MAX_STACK_ALLOC) 540 shdr_info = (struct shdr_info *) xcalloc (shnum + 2, 544 shdr_info = (struct shdr_info *) alloca ((shnum + 2) 546 memset (shdr_info, '\0', (shnum + 2) * sizeof (struct shdr_info)); 652 for (cnt = 1; cnt < shnum; ++cnt) 698 for (cnt = 1; cnt < shnum; ++cnt) 766 if (scnidx == SHN_UNDEF || scnidx >= shnum 826 for (cnt = 1; cnt < shnum; [all...] |
H A D | elflint.c | 350 static unsigned int shnum; variable 427 shnum = ehdr->e_shnum; 454 shnum = shdr->sh_size; 469 if (shdr->sh_link >= shnum) 475 else if (shstrndx >= shnum) 533 for (cnt = idx + 1; cnt < shnum; ++cnt) 565 if (cnt == shnum) 611 for (cnt = 1; cnt < shnum; ++cnt) 626 if (cnt == shnum) 710 || (sym->st_shndx >= shnum [all...] |
H A D | nm.c | 728 size_t shnum; local 729 if (elf_getshnum (ebl->elf, &shnum) < 0) 732 bool scnnames_malloced = shnum * sizeof (const char *) > 128 * 1024; 735 scnnames = (const char **) xmalloc (sizeof (const char *) * shnum); 737 scnnames = (const char **) alloca (sizeof (const char *) * shnum); 814 shnum));
|
H A D | ldgeneric.c | 588 size_t shnum; local 590 if (elf_getshnum (fileinfo->elf, &shnum) < 0) 597 && sym->st_shndx < shnum) 604 buf, sizeof (buf), NULL, shnum); 635 sizeof (buf), NULL, shnum); 1450 size_t shnum; local 1451 assert (elf_getshnum (fileinfo->elf, &shnum) == 0); 1452 assert (shndx < shnum);
|
H A D | readelf.c | 150 static size_t shnum; variable 488 if (elf_getshnum (ebl->elf, &shnum) < 0) 700 for (cnt = 0; cnt < shnum; ++cnt) 854 for (inner = 1; inner < shnum; ++inner) 1737 sizeof (scnbuf), NULL, shnum),
|