Home
last modified time | relevance | path

Searched refs:e_shnum (Results 1 - 25 of 119) sorted by relevance

12345

/kernel/linux/linux-5.10/arch/loongarch/boot/tools/
H A Drelocs.c107 if (shndx < ehdr.e_shnum) in sec_name()
122 for (i = 0; i < ehdr.e_shnum; i++) in sec_lookup()
175 if (ehdr.e_shstrndx >= ehdr.e_shnum) in read_ehdr()
183 secs = calloc(ehdr.e_shnum, sizeof(struct section)); in read_shdrs()
185 die("Unable to allocate %d section headers\n", ehdr.e_shnum); in read_shdrs()
190 for (i = 0; i < ehdr.e_shnum; i++) { in read_shdrs()
196 i, ehdr.e_shnum, strerror(errno)); in read_shdrs()
198 if (sec->shdr.sh_link < ehdr.e_shnum) in read_shdrs()
207 for (i = 0; i < ehdr.e_shnum; i++) { in read_strtabs()
232 for (i = 0; i < ehdr.e_shnum; in read_symtabs()
[all...]
/kernel/linux/linux-5.10/arch/mips/boot/tools/
H A Drelocs.c97 if (shndx < ehdr.e_shnum) in sec_name()
112 for (i = 0; i < ehdr.e_shnum; i++) in sec_lookup()
235 ehdr.e_shnum = elf_half_to_cpu(ehdr.e_shnum); in read_ehdr()
256 if (ehdr.e_shstrndx >= ehdr.e_shnum) in read_ehdr()
265 secs = calloc(ehdr.e_shnum, sizeof(struct section)); in read_shdrs()
267 die("Unable to allocate %d section headers\n", ehdr.e_shnum); in read_shdrs()
272 for (i = 0; i < ehdr.e_shnum; i++) { in read_shdrs()
278 i, ehdr.e_shnum, strerror(errno)); in read_shdrs()
289 if (sec->shdr.sh_link < ehdr.e_shnum) in read_shdrs()
[all...]
/kernel/linux/linux-6.6/arch/mips/boot/tools/
H A Drelocs.c97 if (shndx < ehdr.e_shnum) in sec_name()
112 for (i = 0; i < ehdr.e_shnum; i++) in sec_lookup()
235 ehdr.e_shnum = elf_half_to_cpu(ehdr.e_shnum); in read_ehdr()
256 if (ehdr.e_shstrndx >= ehdr.e_shnum) in read_ehdr()
265 secs = calloc(ehdr.e_shnum, sizeof(struct section)); in read_shdrs()
267 die("Unable to allocate %d section headers\n", ehdr.e_shnum); in read_shdrs()
272 for (i = 0; i < ehdr.e_shnum; i++) { in read_shdrs()
278 i, ehdr.e_shnum, strerror(errno)); in read_shdrs()
289 if (sec->shdr.sh_link < ehdr.e_shnum) in read_shdrs()
[all...]
/kernel/linux/linux-6.6/arch/mips/kernel/
H A Dvpe.c196 for (i = 0; i < hdr->e_shnum; i++) in layout_sections()
200 for (i = 0; i < hdr->e_shnum; ++i) { in layout_sections()
604 if (len < hdr->e_shoff + hdr->e_shnum * sizeof(Elf_Shdr)) { in vpe_elfload()
619 for (i = 1; i < hdr->e_shnum; i++) { in vpe_elfload()
650 for (i = 0; i < hdr->e_shnum; i++) { in vpe_elfload()
671 hdr->e_shnum, &mod); in vpe_elfload()
674 for (i = 1; i < hdr->e_shnum; i++) { in vpe_elfload()
679 if (info >= hdr->e_shnum) in vpe_elfload()
711 for (i = 0; i < hdr->e_shnum; i++) { in vpe_elfload()
/kernel/linux/linux-6.6/kernel/
H A Dkexec_file.c823 for (i = 0; i < pi->ehdr->e_shnum; i++) { in kexec_purgatory_setup_kbuf()
884 sechdrs_size = array_size(sizeof(Elf_Shdr), pi->ehdr->e_shnum); in kexec_purgatory_setup_sechdrs()
895 for (i = 0; i < pi->ehdr->e_shnum; i++) { in kexec_purgatory_setup_sechdrs()
951 for (i = 0; i < pi->ehdr->e_shnum; i++) { in kexec_apply_relocations()
968 if (relsec->sh_info >= pi->ehdr->e_shnum || in kexec_apply_relocations()
969 relsec->sh_link >= pi->ehdr->e_shnum) in kexec_apply_relocations()
982 if (symtab->sh_link >= pi->ehdr->e_shnum) in kexec_apply_relocations()
1068 for (i = 0; i < ehdr->e_shnum; i++) { in kexec_purgatory_find_symbol()
1072 if (sechdrs[i].sh_link >= ehdr->e_shnum) in kexec_purgatory_find_symbol()
1087 syms[k].st_shndx >= ehdr->e_shnum) { in kexec_purgatory_find_symbol()
[all...]
H A Dkexec_elf.c68 } else if (ehdr->e_shnum > 0 && in elf_is_ehdr_sane()
97 if (ehdr->e_shoff > 0 && ehdr->e_shnum > 0) { in elf_is_ehdr_sane()
101 * e_shnum is at most 65536 so calculating in elf_is_ehdr_sane()
104 shdr_size = sizeof(struct elf_shdr) * ehdr->e_shnum; in elf_is_ehdr_sane()
157 ehdr->e_shnum = elf16_to_cpu(ehdr, buf_ehdr->e_shnum); in elf_read_ehdr()
/kernel/linux/linux-5.10/arch/mips/kernel/
H A Dvpe.c196 for (i = 0; i < hdr->e_shnum; i++) in layout_sections()
200 for (i = 0; i < hdr->e_shnum; ++i) { in layout_sections()
605 if (len < hdr->e_shoff + hdr->e_shnum * sizeof(Elf_Shdr)) { in vpe_elfload()
620 for (i = 1; i < hdr->e_shnum; i++) { in vpe_elfload()
651 for (i = 0; i < hdr->e_shnum; i++) { in vpe_elfload()
672 hdr->e_shnum, &mod); in vpe_elfload()
675 for (i = 1; i < hdr->e_shnum; i++) { in vpe_elfload()
680 if (info >= hdr->e_shnum) in vpe_elfload()
712 for (i = 0; i < hdr->e_shnum; i++) { in vpe_elfload()
/kernel/linux/linux-5.10/kernel/
H A Dkexec_elf.c68 } else if (ehdr->e_shnum > 0 && in elf_is_ehdr_sane()
97 if (ehdr->e_shoff > 0 && ehdr->e_shnum > 0) { in elf_is_ehdr_sane()
101 * e_shnum is at most 65536 so calculating in elf_is_ehdr_sane()
104 shdr_size = sizeof(struct elf_shdr) * ehdr->e_shnum; in elf_is_ehdr_sane()
157 ehdr->e_shnum = elf16_to_cpu(ehdr, buf_ehdr->e_shnum); in elf_read_ehdr()
H A Dkexec_file.c826 for (i = 0; i < pi->ehdr->e_shnum; i++) { in kexec_purgatory_setup_kbuf()
886 sechdrs = vzalloc(array_size(sizeof(Elf_Shdr), pi->ehdr->e_shnum)); in kexec_purgatory_setup_sechdrs()
890 pi->ehdr->e_shnum * sizeof(Elf_Shdr)); in kexec_purgatory_setup_sechdrs()
897 for (i = 0; i < pi->ehdr->e_shnum; i++) { in kexec_purgatory_setup_sechdrs()
953 for (i = 0; i < pi->ehdr->e_shnum; i++) { in kexec_apply_relocations()
970 if (relsec->sh_info >= pi->ehdr->e_shnum || in kexec_apply_relocations()
971 relsec->sh_link >= pi->ehdr->e_shnum) in kexec_apply_relocations()
984 if (symtab->sh_link >= pi->ehdr->e_shnum) in kexec_apply_relocations()
1070 for (i = 0; i < ehdr->e_shnum; i++) { in kexec_purgatory_find_symbol()
1074 if (sechdrs[i].sh_link >= ehdr->e_shnum) in kexec_purgatory_find_symbol()
[all...]
H A Dmodule.c357 for (i = 1; i < info->hdr->e_shnum; i++) { in find_sec()
1604 for (i = 0; i < info->hdr->e_shnum; i++) in add_sect_attrs()
1621 for (i = 0; i < info->hdr->e_shnum; i++) { in add_sect_attrs()
1705 for (i = 0; i < info->hdr->e_shnum; i++) in add_notes_attrs()
1720 for (loaded = i = 0; i < info->hdr->e_shnum; ++i) { in add_notes_attrs()
2102 for (i = 0; i < hdr->e_shnum; i++) { in module_enforce_rwx_sections()
2144 size = sizeof(*info->sechdrs) * info->hdr->e_shnum; in copy_module_elf()
2438 for (i = 1; i < info->hdr->e_shnum; i++) { in apply_relocations()
2442 if (infosec >= info->hdr->e_shnum) in apply_relocations()
2505 for (i = 0; i < info->hdr->e_shnum; in layout_sections()
[all...]
/kernel/linux/linux-5.10/arch/powerpc/boot/
H A Delf.h68 Elf32_Half e_shnum; member
85 Elf64_Half e_shnum; member
/kernel/linux/linux-5.10/arch/mips/vdso/
H A Dgenvdso.h16 sh_count = swap_uint16(ehdr->e_shnum); in patch_vdso()
70 sh_count = swap_uint16(ehdr->e_shnum); in get_symbols()
/kernel/linux/linux-6.6/arch/powerpc/boot/
H A Delf.h68 Elf32_Half e_shnum; member
85 Elf64_Half e_shnum; member
/kernel/linux/linux-6.6/arch/mips/vdso/
H A Dgenvdso.h16 sh_count = swap_uint16(ehdr->e_shnum); in patch_vdso()
70 sh_count = swap_uint16(ehdr->e_shnum); in get_symbols()
/kernel/linux/linux-5.10/scripts/
H A Dinsert-sys-cert.c74 if (hdr->e_shnum == SHN_UNDEF) in get_offset_from_address()
77 num_sections = hdr->e_shnum; in get_offset_from_address()
190 if (hdr->e_shnum == SHN_UNDEF) in get_symbol_table()
193 num_sections = hdr->e_shnum; in get_symbol_table()
/kernel/linux/linux-6.6/kernel/module/
H A Dsysfs.c80 for (i = 0; i < info->hdr->e_shnum; i++) in add_sect_attrs()
97 for (i = 0; i < info->hdr->e_shnum; i++) { in add_sect_attrs()
184 for (i = 0; i < info->hdr->e_shnum; i++) in add_notes_attrs()
199 for (loaded = i = 0; i < info->hdr->e_shnum; ++i) { in add_notes_attrs()
H A Ddebug_kmemleak.c20 for (i = 1; i < info->hdr->e_shnum; i++) { in kmemleak_load_module()
/kernel/linux/linux-6.6/scripts/
H A Dinsert-sys-cert.c74 if (hdr->e_shnum == SHN_UNDEF) in get_offset_from_address()
77 num_sections = hdr->e_shnum; in get_offset_from_address()
190 if (hdr->e_shnum == SHN_UNDEF) in get_symbol_table()
193 num_sections = hdr->e_shnum; in get_symbol_table()
/kernel/linux/linux-5.10/arch/loongarch/kernel/
H A Dmodule-sections.c113 for (i = 0; i < ehdr->e_shnum; i++) { in module_frob_arch_sections()
138 for (i = 0; i < ehdr->e_shnum; i++) { in module_frob_arch_sections()
/kernel/linux/linux-5.10/arch/sparc/kernel/
H A Dmodule.c66 if (symidx == hdr->e_shnum-1) { in module_frob_arch_sections()
190 for (s = sechdrs; s < sechdrs + hdr->e_shnum; s++) { in do_patch_sections()
/kernel/linux/linux-5.10/arch/riscv/kernel/
H A Dmodule-sections.c100 for (i = 0; i < ehdr->e_shnum; i++) { in module_frob_arch_sections()
123 for (i = 0; i < ehdr->e_shnum; i++) { in module_frob_arch_sections()
/kernel/linux/linux-6.6/arch/loongarch/kernel/
H A Dmodule-sections.c113 for (i = 0; i < ehdr->e_shnum; i++) { in module_frob_arch_sections()
138 for (i = 0; i < ehdr->e_shnum; i++) { in module_frob_arch_sections()
/kernel/linux/linux-6.6/arch/riscv/kernel/
H A Dmodule-sections.c100 for (i = 0; i < ehdr->e_shnum; i++) { in module_frob_arch_sections()
123 for (i = 0; i < ehdr->e_shnum; i++) { in module_frob_arch_sections()
/kernel/linux/linux-6.6/arch/sparc/kernel/
H A Dmodule.c66 if (symidx == hdr->e_shnum-1) { in module_frob_arch_sections()
190 for (s = sechdrs; s < sechdrs + hdr->e_shnum; s++) { in do_patch_sections()
/kernel/linux/linux-6.6/arch/arm64/include/asm/
H A Dmodule.h61 for (s = sechdrs, se = sechdrs + hdr->e_shnum; s < se; s++) { in find_section()

Completed in 19 milliseconds

12345