Home
last modified time | relevance | path

Searched refs:shdr (Results 1 – 8 of 8) sorted by relevance

/arch/mips/boot/tools/
Drelocs.c25 Elf_Shdr shdr; member
98 name = sec_strtab + secs[shndx].shdr.sh_name; in sec_name()
263 Elf_Shdr shdr; in read_shdrs() local
276 if (fread(&shdr, sizeof(shdr), 1, fp) != 1) in read_shdrs()
279 sec->shdr.sh_name = elf_word_to_cpu(shdr.sh_name); in read_shdrs()
280 sec->shdr.sh_type = elf_word_to_cpu(shdr.sh_type); in read_shdrs()
281 sec->shdr.sh_flags = elf_xword_to_cpu(shdr.sh_flags); in read_shdrs()
282 sec->shdr.sh_addr = elf_addr_to_cpu(shdr.sh_addr); in read_shdrs()
283 sec->shdr.sh_offset = elf_off_to_cpu(shdr.sh_offset); in read_shdrs()
284 sec->shdr.sh_size = elf_xword_to_cpu(shdr.sh_size); in read_shdrs()
[all …]
/arch/mips/vdso/
Dgenvdso.h11 ELF(Shdr) *shdr; in FUNC()
19 shdr = shdrs + (sh_entsize * swap_uint16(ehdr->e_shstrndx)); in FUNC()
20 shstrtab = vdso + FUNC(swap_uint)(shdr->sh_offset); in FUNC()
23 shdr = shdrs + (i * sh_entsize); in FUNC()
24 name = shstrtab + swap_uint32(shdr->sh_name); in FUNC()
31 switch (swap_uint32(shdr->sh_type)) { in FUNC()
50 shdr->sh_type = swap_uint32(SHT_MIPS_ABIFLAGS); in FUNC()
51 shdr->sh_entsize = shdr->sh_size; in FUNC()
62 ELF(Shdr) *shdr; in FUNC()
74 shdr = shdrs + (i * sh_entsize); in FUNC()
[all …]
/arch/riscv/kernel/
Dmodule-sections.c23 got = (struct got_entry *)got_sec->shdr->sh_addr; in module_emit_got_entry()
44 got_plt = (struct got_entry *)got_plt_sec->shdr->sh_addr; in module_emit_plt_entry()
46 plt = (struct plt_entry *)plt_sec->shdr->sh_addr; in module_emit_plt_entry()
102 mod->arch.plt.shdr = sechdrs + i; in module_frob_arch_sections()
104 mod->arch.got.shdr = sechdrs + i; in module_frob_arch_sections()
106 mod->arch.got_plt.shdr = sechdrs + i; in module_frob_arch_sections()
109 if (!mod->arch.plt.shdr) { in module_frob_arch_sections()
113 if (!mod->arch.got.shdr) { in module_frob_arch_sections()
117 if (!mod->arch.got_plt.shdr) { in module_frob_arch_sections()
138 mod->arch.plt.shdr->sh_type = SHT_NOBITS; in module_frob_arch_sections()
[all …]
/arch/x86/tools/
Drelocs.c32 Elf_Shdr shdr; member
250 name = sec_strtab + secs[shndx].shdr.sh_name; in sec_name()
284 if (sec->shdr.sh_type != SHT_SYMTAB) in sym_lookup()
287 nsyms = sec->shdr.sh_size/sizeof(Elf_Sym); in sym_lookup()
390 Elf_Shdr shdr; in read_ehdr() local
395 if (fread(&shdr, sizeof(shdr), 1, fp) != 1) in read_ehdr()
399 shnum = elf_xword_to_cpu(shdr.sh_size); in read_ehdr()
402 shstrndx = elf_word_to_cpu(shdr.sh_link); in read_ehdr()
412 Elf_Shdr shdr; in read_shdrs() local
425 if (fread(&shdr, sizeof(shdr), 1, fp) != 1) in read_shdrs()
[all …]
/arch/powerpc/boot/
Dhack-coff.c35 struct external_scnhdr shdr; in main() local
57 if (read(fd, &shdr, sizeof(shdr)) != sizeof(shdr)) in main()
59 if (strcmp(shdr.s_name, ".text") == 0) { in main()
62 } else if (strcmp(shdr.s_name, ".data") == 0) { in main()
64 } else if (strcmp(shdr.s_name, ".bss") == 0) { in main()
/arch/arm64/kvm/hyp/nvhe/
Dgen-hyprel.c205 #define for_each_rela(shdr, var) \ argument
206 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++)
216 static inline const char *section_name(Elf64_Shdr *shdr) in section_name() argument
218 return elf.sh_string + elf32toh(shdr->sh_name); in section_name()
222 static inline const char *section_begin(Elf64_Shdr *shdr) in section_begin() argument
224 return elf_ptr(char, elf64toh(shdr->sh_offset)); in section_begin()
428 Elf64_Shdr *shdr; in emit_all_relocs() local
430 for_each_section(shdr) { in emit_all_relocs()
431 switch (elf32toh(shdr->sh_type)) { in emit_all_relocs()
[all …]
/arch/powerpc/oprofile/cell/
Dvma_map.c114 Elf32_Shdr shdr, shdr_str; in create_vma_map() local
171 if (copy_from_user(&shdr, shdr_start + i, sizeof(shdr))) in create_vma_map()
174 if (shdr.sh_type != SHT_SYMTAB) in create_vma_map()
176 if (shdr.sh_entsize != sizeof (sym)) in create_vma_map()
180 shdr_start + shdr.sh_link, in create_vma_map()
181 sizeof(shdr))) in create_vma_map()
187 for (j = 0; j < shdr.sh_size / sizeof (sym); j++) { in create_vma_map()
189 shdr.sh_offset + in create_vma_map()
/arch/riscv/include/asm/
Dmodule.h15 Elf_Shdr *shdr; member
38 struct got_entry *got = (struct got_entry *)(sec->shdr->sh_addr); in get_got_entry()
91 struct got_entry *got_plt = (struct got_entry *)sec->shdr->sh_addr; in get_got_plt_idx()
104 struct plt_entry *plt = (struct plt_entry *)sec_plt->shdr->sh_addr; in get_plt_entry()