Home
last modified time | relevance | path

Searched refs:sh_offset (Results 1 – 25 of 71) sorted by relevance

123

/openbmc/openbmc/poky/scripts/
H A Drelocate_sdk.py124 sh_offset, sh_size = struct.unpack(endian_prefix + "16xII16x", sh_hdr)
126 sh_offset, sh_size = struct.unpack(endian_prefix + "24xQQ24x", sh_hdr)
128 f.seek(sh_offset)
138 sh_name, sh_type, sh_flags, sh_addr, sh_offset, sh_size, sh_link,\
145 f.seek(sh_offset)
150 sysdirs_off = sh_offset
154 sysdirslen_off = sh_offset
166 f.seek(sh_offset)
182 f.seek(sh_offset + offset)
/openbmc/linux/scripts/
H A Dsorttable.h219 + _r(&(emloc->init_data_sec)->sh_offset); in sort_mcount_loc()
303 secstrings = (const char *)ehdr + _r(&shdr[shstrndx].sh_offset); in do_sort()
323 relocs = (void *)ehdr + _r(&s->sh_offset); in do_sort()
328 _r(&s->sh_offset)); in do_sort()
346 s->sh_offset); in do_sort()
351 s->sh_offset); in do_sort()
414 extab_image = (void *)ehdr + _r(&extab_sec->sh_offset); in do_sort()
415 strtab = (const char *)ehdr + _r(&strtab_sec->sh_offset); in do_sort()
417 _r(&symtab_sec->sh_offset)); in do_sort()
432 for (sym = (void *)ehdr + _r(&symtab_sec->sh_offset); in do_sort()
[all …]
H A Drecordmcount.h248 *symtab = (void *)ehdr + relhdr->sh_offset; in find_symtab()
250 *symtab_shndx = (void *)ehdr + relhdr->sh_offset; in find_symtab()
274 uint_t const old_shstr_sh_offset = _w(shstr->sh_offset); in append_func()
282 shstr->sh_offset = _w(sb.st_size); in append_func()
312 mcsec.sh_offset = _w(t); in append_func()
327 mcsec.sh_offset = _w((void *)mlocp - (void *)mloc0 + t); in append_func()
383 Elf_Rel const *const rel0 = (Elf_Rel const *)(_w(relhdr->sh_offset) in get_sym_str_and_relp()
386 *sym0 = (Elf_Sym const *)(_w(symsec->sh_offset) in get_sym_str_and_relp()
389 *str0 = (char const *)(_w(strsec->sh_offset) in get_sym_str_and_relp()
477 ret = make_nop((void *)ehdr, _w(shdr->sh_offset) + _w(relp->r_offset)); in nop_mcount()
[all …]
H A Dinsert-sys-cert.c82 unsigned long offset = x[i].sh_offset; in get_offset_from_address()
143 symtab_start = (void *)hdr + symtab->sh_offset; in find_elf_symbol()
145 strtab = (void *)hdr + x[link].sh_offset; in find_elf_symbol()
179 + sec->sh_offset; in get_symbol_from_table()
/openbmc/linux/arch/x86/entry/vdso/
H A Dvdso2c.h32 offset = (unsigned long)GET_LE(&sec->sh_offset); in BITSFUNC()
105 secstrings = raw_addr + GET_LE(&secstrings_hdr->sh_offset); in BITSFUNC()
129 ELF(Sym) *sym = raw_addr + GET_LE(&symtab_hdr->sh_offset) + in BITSFUNC()
132 GET_LE(&strtab_hdr->sh_offset) + in BITSFUNC()
205 (unsigned long)GET_LE(&alt_sec->sh_offset)); in BITSFUNC()
211 (unsigned long)GET_LE(&extable_sec->sh_offset)); in BITSFUNC()
/openbmc/u-boot/tools/
H A Dmips-relocs.c204 uintptr_t sh_offset; in main() local
288 shstrtab = elf + shdr_field(ehdr_field(e_shstrndx), sh_offset); in main()
346 sh_offset = shdr_field(i, sh_offset); in main()
369 err = parse_fn(elf + sh_offset + (j * sh_entsize)); in main()
383 buf = buf_start = elf + shdr_field(i_rel_shdr, sh_offset); in main()
H A Dimg2srec.c286 getPtr = ExtractLong((uint32_t *)&sectHeader[i].sh_offset, getPtr); in ConvertELF()
318 loadDiff = loadAddr - sectHeader[i].sh_offset; in ConvertELF()
321 loadAddr = sectHeader[i].sh_offset + loadDiff; in ConvertELF()
329 fseek(file, sectHeader[i].sh_offset, SEEK_SET); in ConvertELF()
/openbmc/linux/arch/mips/boot/tools/
H A Drelocs.c283 sec->shdr.sh_offset = elf_off_to_cpu(shdr.sh_offset); in read_shdrs()
309 if (fseek(fp, sec->shdr.sh_offset, SEEK_SET) < 0) in read_strtabs()
311 sec->shdr.sh_offset, strerror(errno)); in read_strtabs()
333 if (fseek(fp, sec->shdr.sh_offset, SEEK_SET) < 0) in read_symtabs()
335 sec->shdr.sh_offset, strerror(errno)); in read_symtabs()
377 if (fseek(fp, sec->shdr.sh_offset, SEEK_SET) < 0) in read_relocs()
379 sec->shdr.sh_offset, strerror(errno)); in read_relocs()
607 if (fseek(outf, sec_reloc->shdr.sh_offset, SEEK_SET) < 0) { in emit_relocs()
609 sec_reloc->shdr.sh_offset, strerror(errno)); in emit_relocs()
/openbmc/linux/arch/mips/vdso/
H A Dgenvdso.h20 shstrtab = vdso + FUNC(swap_uint)(shdr->sh_offset); in FUNC()
96 symtab = vdso + FUNC(swap_uint)(shdr->sh_offset); in FUNC()
102 strtab = vdso + FUNC(swap_uint)(shdr->sh_offset); in FUNC()
/openbmc/linux/arch/s390/kernel/
H A Dmachine_kexec_file.c312 strtab = (char *)pi->ehdr + sechdrs[symtab->sh_link].sh_offset; in arch_kexec_apply_relocations_add()
313 shstrtab = (char *)pi->ehdr + sechdrs[pi->ehdr->e_shstrndx].sh_offset; in arch_kexec_apply_relocations_add()
315 relas = (void *)pi->ehdr + relsec->sh_offset; in arch_kexec_apply_relocations_add()
323 sym = (void *)pi->ehdr + symtab->sh_offset; in arch_kexec_apply_relocations_add()
349 loc += section->sh_offset; in arch_kexec_apply_relocations_add()
/openbmc/linux/arch/x86/tools/
H A Drelocs.c459 sec->shdr.sh_offset = elf_off_to_cpu(shdr.sh_offset); in read_shdrs()
484 if (fseek(fp, sec->shdr.sh_offset, SEEK_SET) < 0) { in read_strtabs()
486 sec->shdr.sh_offset, strerror(errno)); in read_strtabs()
511 if (fseek(fp, sec->shdr.sh_offset, SEEK_SET) < 0) { in read_symtabs()
513 sec->shdr.sh_offset, strerror(errno)); in read_symtabs()
531 if (fseek(fp, sec->shdr.sh_offset, SEEK_SET) < 0) { in read_symtabs()
533 sec->shdr.sh_offset, strerror(errno)); in read_symtabs()
571 if (fseek(fp, sec->shdr.sh_offset, SEEK_SET) < 0) { in read_relocs()
573 sec->shdr.sh_offset, strerror(errno)); in read_relocs()
/openbmc/linux/arch/riscv/kernel/
H A Delf_kexec.c377 strtab = (char *)pi->ehdr + sechdrs[symtab->sh_link].sh_offset; in arch_kexec_apply_relocations_add()
378 shstrtab = (char *)pi->ehdr + sechdrs[pi->ehdr->e_shstrndx].sh_offset; in arch_kexec_apply_relocations_add()
380 relas = (void *)pi->ehdr + relsec->sh_offset; in arch_kexec_apply_relocations_add()
389 sym = (void *)pi->ehdr + symtab->sh_offset; in arch_kexec_apply_relocations_add()
398 loc += section->sh_offset; in arch_kexec_apply_relocations_add()
H A Dalternative.c185 begin = (void *)hdr + alt->sh_offset, in apply_vdso_alternatives()
186 end = (void *)hdr + alt->sh_offset + alt->sh_size, in apply_vdso_alternatives()
/openbmc/linux/arch/x86/kernel/
H A Dmachine_kexec_64.c439 strtab = (char *)pi->ehdr + sechdrs[symtabsec->sh_link].sh_offset; in arch_kexec_apply_relocations_add()
440 shstrtab = (char *)pi->ehdr + sechdrs[pi->ehdr->e_shstrndx].sh_offset; in arch_kexec_apply_relocations_add()
442 rel = (void *)pi->ehdr + relsec->sh_offset; in arch_kexec_apply_relocations_add()
460 location += section->sh_offset; in arch_kexec_apply_relocations_add()
472 sym = (void *)pi->ehdr + symtabsec->sh_offset; in arch_kexec_apply_relocations_add()
/openbmc/linux/arch/sparc/vdso/
H A Dvma.c76 snames = (void *)e->hdr + shdrs[e->hdr->e_shstrndx].sh_offset; in one_section64()
81 return (void *)e->hdr + shdrs[i].sh_offset; in one_section64()
144 snames = (void *)e->hdr + shdrs[e->hdr->e_shstrndx].sh_offset; in one_section32()
149 return (void *)e->hdr + shdrs[i].sh_offset; in one_section32()
H A Dvdso2c.h84 ELF(Sym) *sym = raw_addr + GET_BE(&symtab_hdr->sh_offset) + in BITSFUNC()
86 const char *name = raw_addr + GET_BE(&strtab_hdr->sh_offset) + in BITSFUNC()
/openbmc/u-boot/cmd/
H A Delf.c91 strtab = (unsigned char *)(addr + (ulong)shdr->sh_offset); in load_elf64_image_shdr()
115 image = (unsigned char *)addr + (ulong)shdr->sh_offset; in load_elf64_image_shdr()
196 strtab = (unsigned char *)(addr + shdr->sh_offset); in load_elf_image_shdr()
220 image = (unsigned char *)addr + shdr->sh_offset; in load_elf_image_shdr()
/openbmc/linux/arch/mips/kernel/
H A Dvpe.c612 secstrings = (void *)hdr + sechdrs[hdr->e_shstrndx].sh_offset; in vpe_elfload()
621 (len < sechdrs[i].sh_offset + sechdrs[i].sh_size)) { in vpe_elfload()
630 sechdrs[i].sh_offset; in vpe_elfload()
637 sechdrs[strindex].sh_offset; in vpe_elfload()
717 sechdrs[strindex].sh_offset; in vpe_elfload()
724 sechdrs[i].sh_offset; in vpe_elfload()
/openbmc/linux/arch/arm64/kvm/hyp/nvhe/
H A Dgen-hyprel.c206 for (var = elf_ptr(Elf64_Rela, elf64toh(shdr->sh_offset)); \
207 var < elf_ptr(Elf64_Rela, elf64toh(shdr->sh_offset) + elf64toh(shdr->sh_size)); var++)
224 return elf_ptr(char, elf64toh(shdr->sh_offset)); in section_begin()
/openbmc/linux/scripts/mod/
H A Dmodpost.c339 return (void *)info->hdr + sechdr->sh_offset + offset; in sym_get_data_by_offset()
506 sechdrs[i].sh_offset = TO_NATIVE(sechdrs[i].sh_offset); in parse_elf()
514 secstrings = (void *)hdr + sechdrs[info->secindex_strings].sh_offset; in parse_elf()
519 if (!nobits && sechdrs[i].sh_offset > info->size) { in parse_elf()
521 filename, (unsigned long)sechdrs[i].sh_offset, in parse_elf()
529 info->modinfo = (void *)hdr + sechdrs[i].sh_offset; in parse_elf()
539 sechdrs[i].sh_offset; in parse_elf()
541 sechdrs[i].sh_offset + sechdrs[i].sh_size; in parse_elf()
544 sechdrs[sh_link_idx].sh_offset; in parse_elf()
551 sechdrs[i].sh_offset; in parse_elf()
[all …]
/openbmc/linux/tools/perf/util/
H A Dsymbol-elf.c609 vi.offset = shdr->sh_offset + di->plt_got_data->d_off + i + disp; in get_plt_got_name()
652 snprintf(buf, buf_sz, "offset_%#" PRIx64 "@plt", (u64)shdr.sh_offset + i); in dso__synthesize_plt_got_symbols()
653 sym = symbol__new(shdr.sh_offset + i, shdr.sh_entsize, STB_GLOBAL, STT_FUNC, buf); in dso__synthesize_plt_got_symbols()
699 f = dso__find_symbol_nocache(dso, shdr_plt.sh_offset); in dso__synthesize_plt_symbols()
700 if (f && f->start < shdr_plt.sh_offset && f->end > shdr_plt.sh_offset) in dso__synthesize_plt_symbols()
701 f->end = shdr_plt.sh_offset; in dso__synthesize_plt_symbols()
707 plt_sym = symbol__new(shdr_plt.sh_offset, plt_header_size, STB_GLOBAL, STT_FUNC, ".plt"); in dso__synthesize_plt_symbols()
725 plt_offset = plt_sec_shdr.sh_offset; in dso__synthesize_plt_symbols()
728 plt_offset = shdr_plt.sh_offset; in dso__synthesize_plt_symbols()
1379 sym->st_value -= shdr->sh_addr - shdr->sh_offset; in dso__process_kernel_symbol()
[all …]
/openbmc/linux/drivers/remoteproc/
H A Dremoteproc_elf_loader.c334 u64 sh_offset; local
340 sh_offset = elf_shdr_get_sh_offset(class, shdr);
341 table = (struct resource_table *)(elf_data + sh_offset);
/openbmc/linux/arch/powerpc/kernel/
H A Dmodule_32.c97 (void *)hdr + sechdrs[i].sh_offset, in get_plt_size()
105 sort((void *)hdr + sechdrs[i].sh_offset, in get_plt_size()
110 + sechdrs[i].sh_offset, in get_plt_size()
/openbmc/linux/arch/arm/kernel/
H A Dvdso.c113 secnames = (void *)ehdr + sechdrs[ehdr->e_shstrndx].sh_offset; in find_section()
120 return (void *)ehdr + sechdrs[i].sh_offset; in find_section()
/openbmc/linux/arch/arm64/kernel/
H A Dalternative.c215 .begin = (void *)hdr + alt->sh_offset, in apply_alternatives_vdso()
216 .end = (void *)hdr + alt->sh_offset + alt->sh_size, in apply_alternatives_vdso()

123