• Home
  • Raw
  • Download

Lines Matching refs:idx

99 					     unsigned int idx)  in find_section_by_index()  argument
103 elf_hash_for_each_possible(section, sec, hash, idx) { in find_section_by_index()
104 if (sec->idx == idx) in find_section_by_index()
111 static struct symbol *find_symbol_by_index(struct elf *elf, unsigned int idx) in find_symbol_by_index() argument
115 elf_hash_for_each_possible(symbol, sym, hash, idx) { in find_symbol_by_index()
116 if (sym->idx == idx) in find_symbol_by_index()
263 sec->idx = elf_ndxscn(s); in read_sections()
294 elf_hash_add(section, &sec->hash, sec->idx); in read_sections()
332 elf_hash_add(symbol, &sym->hash, sym->idx); in elf_add_symbol()
381 sym->idx = i; in read_symbols()
553 Elf32_Word shndx = sym->sec ? sym->sec->idx : SHN_UNDEF; in elf_update_symbol()
556 int max_idx, idx = sym->idx; in elf_update_symbol() local
564 s = elf_getscn(elf->elf, symtab->idx); in elf_update_symbol()
571 t = elf_getscn(elf->elf, symtab_shndx->idx); in elf_update_symbol()
588 if (idx) { in elf_update_symbol()
614 shndx_data->d_buf = &sym->sec->idx; in elf_update_symbol()
634 if (idx < max_idx) in elf_update_symbol()
638 idx -= max_idx; in elf_update_symbol()
642 if (idx < 0) { in elf_update_symbol()
660 if (!gelf_update_symshndx(symtab_data, shndx_data, idx, &sym->sym, shndx)) { in elf_update_symbol()
706 old->idx = new_idx; in elf_create_section_symbol()
709 elf_hash_add(symbol, &old->hash, old->idx); in elf_create_section_symbol()
721 sym->idx = new_idx; in elf_create_section_symbol()
833 reloc->idx = i; in read_relocs()
929 s = elf_getscn(elf->elf, strtab->idx); in elf_add_string()
981 sec->idx = elf_ndxscn(s); in elf_create_section()
1026 elf_hash_add(section, &sec->hash, sec->idx); in elf_create_section()
1057 sec->sh.sh_link = find_section_by_name(elf, ".symtab")->idx; in elf_create_rel_reloc_section()
1058 sec->sh.sh_info = base->idx; in elf_create_rel_reloc_section()
1087 sec->sh.sh_link = find_section_by_name(elf, ".symtab")->idx; in elf_create_rela_reloc_section()
1088 sec->sh.sh_info = base->idx; in elf_create_rela_reloc_section()
1108 int idx = 0; in elf_rebuild_rel_reloc_section() local
1122 idx = 0; in elf_rebuild_rel_reloc_section()
1125 reloc->rel.r_info = GELF_R_INFO(reloc->sym->idx, reloc->type); in elf_rebuild_rel_reloc_section()
1126 if (!gelf_update_rel(sec->data, idx, &reloc->rel)) { in elf_rebuild_rel_reloc_section()
1130 idx++; in elf_rebuild_rel_reloc_section()
1139 int idx = 0; in elf_rebuild_rela_reloc_section() local
1153 idx = 0; in elf_rebuild_rela_reloc_section()
1157 reloc->rela.r_info = GELF_R_INFO(reloc->sym->idx, reloc->type); in elf_rebuild_rela_reloc_section()
1158 if (!gelf_update_rela(sec->data, idx, &reloc->rela)) { in elf_rebuild_rela_reloc_section()
1162 idx++; in elf_rebuild_rela_reloc_section()
1201 reloc->rel.r_info = GELF_R_INFO(reloc->sym->idx, reloc->type); in elf_write_reloc()
1204 if (!gelf_update_rel(sec->data, reloc->idx, &reloc->rel)) { in elf_write_reloc()
1209 reloc->rela.r_info = GELF_R_INFO(reloc->sym->idx, reloc->type); in elf_write_reloc()
1213 if (!gelf_update_rela(sec->data, reloc->idx, &reloc->rela)) { in elf_write_reloc()
1232 s = elf_getscn(elf->elf, sec->idx); in elf_write()