Home
last modified time | relevance | path

Searched refs:sh_size (Results 1 – 25 of 79) sorted by relevance

1234

/linux-6.12.1/arch/x86/kernel/
Dmodule.c53 for (i = 0; i < sechdrs[relsec].sh_size / sizeof(*rel); i++) { in apply_relocate()
99 for (i = 0; i < sechdrs[relsec].sh_size / sizeof(*rel); i++) { in __write_relocate_add()
260 rsize = retpolines->sh_size; in module_finalize()
265 csize = cfi->sh_size; in module_finalize()
272 apply_retpolines(rseg, rseg + retpolines->sh_size); in module_finalize()
276 apply_returns(rseg, rseg + returns->sh_size); in module_finalize()
281 apply_alternatives(aseg, aseg + alt->sh_size); in module_finalize()
288 cs.call_end = (void *)calls->sh_addr + calls->sh_size; in module_finalize()
293 cs.alt_end = (void *)alt->sh_addr + alt->sh_size; in module_finalize()
300 apply_seal_endbr(iseg, iseg + ibt_endbr->sh_size); in module_finalize()
[all …]
/linux-6.12.1/arch/powerpc/kernel/
Dmodule.c48 (void *)sect->sh_addr + sect->sh_size); in module_finalize()
54 (void *)sect->sh_addr + sect->sh_size); in module_finalize()
61 (void *)sect->sh_addr + sect->sh_size); in module_finalize()
68 me->arch.end_opd = sect->sh_addr + sect->sh_size; in module_finalize()
77 (void *)sect->sh_addr + sect->sh_size); in module_finalize()
84 (void *)sect->sh_addr + sect->sh_size); in module_finalize()
Dmodule_64.c220 sechdrs[i].sh_size / sizeof(Elf64_Rela)); in get_stubs_size()
228 sechdrs[i].sh_size / sizeof(Elf64_Rela), in get_stubs_size()
232 sechdrs[i].sh_size in get_stubs_size()
237 sechdrs[i].sh_size in get_stubs_size()
309 sechdrs[i].sh_size / sizeof(Elf64_Rela)); in get_got_size()
318 sechdrs[i].sh_size / sizeof(Elf64_Rela), in get_got_size()
322 sechdrs[i].sh_size in get_got_size()
335 sechdrs[i].sh_size in get_got_size()
386 numsyms = sechdrs[symindex].sh_size / sizeof(Elf64_Sym); in find_dot_toc()
430 sechdrs[i].sh_size); in module_frob_arch_sections()
[all …]
Dmodule_32.c98 sechdrs[i].sh_size / sizeof(Elf32_Rela)); in get_plt_size()
106 sechdrs[i].sh_size / sizeof(Elf32_Rela), in get_plt_size()
111 sechdrs[i].sh_size in get_plt_size()
140 sechdrs[me->arch.core_plt_section].sh_size in module_frob_arch_sections()
142 sechdrs[me->arch.init_plt_section].sh_size in module_frob_arch_sections()
210 for (i = 0; i < sechdrs[relsec].sh_size / sizeof(*rela); i++) { in apply_relocate_add()
/linux-6.12.1/arch/mips/boot/tools/
Drelocs.c284 sec->shdr.sh_size = elf_xword_to_cpu(shdr.sh_size); in read_shdrs()
304 sec->strtab = malloc(sec->shdr.sh_size); in read_strtabs()
307 sec->shdr.sh_size); in read_strtabs()
313 if (fread(sec->strtab, 1, sec->shdr.sh_size, fp) != in read_strtabs()
314 sec->shdr.sh_size) in read_strtabs()
328 sec->symtab = malloc(sec->shdr.sh_size); in read_symtabs()
331 sec->shdr.sh_size); in read_symtabs()
337 if (fread(sec->symtab, 1, sec->shdr.sh_size, fp) != in read_symtabs()
338 sec->shdr.sh_size) in read_symtabs()
341 for (j = 0; j < sec->shdr.sh_size/sizeof(Elf_Sym); j++) { in read_symtabs()
[all …]
/linux-6.12.1/arch/x86/tools/
Drelocs.c301 nsyms = sec->shdr.sh_size/sizeof(Elf_Sym); in sym_lookup()
426 shnum = elf_xword_to_cpu(shdr.sh_size); in read_ehdr()
459 sec->shdr.sh_size = elf_xword_to_cpu(shdr.sh_size); in read_shdrs()
480 sec->strtab = malloc(sec->shdr.sh_size); in read_strtabs()
482 die("malloc of %" FMT " bytes for strtab failed\n", sec->shdr.sh_size); in read_strtabs()
487 if (fread(sec->strtab, 1, sec->shdr.sh_size, fp) != sec->shdr.sh_size) in read_strtabs()
502 sec->xsymtab = malloc(sec->shdr.sh_size); in read_symtabs()
504 die("malloc of %" FMT " bytes for xsymtab failed\n", sec->shdr.sh_size); in read_symtabs()
509 if (fread(sec->xsymtab, 1, sec->shdr.sh_size, fp) != sec->shdr.sh_size) in read_symtabs()
516 num_syms = sec->shdr.sh_size / sizeof(Elf_Sym); in read_symtabs()
[all …]
/linux-6.12.1/arch/s390/tools/
Drelocs.c172 shnum = elf_xword_to_cpu(shdr.sh_size); in read_ehdr()
207 sec->shdr.sh_size = elf_xword_to_cpu(shdr.sh_size); in read_shdrs()
229 sec->reltab = malloc(sec->shdr.sh_size); in read_relocs()
231 die("malloc of %" FMT " bytes for relocs failed\n", sec->shdr.sh_size); in read_relocs()
236 if (fread(sec->reltab, 1, sec->shdr.sh_size, fp) != sec->shdr.sh_size) in read_relocs()
239 for (j = 0; j < sec->shdr.sh_size / sizeof(Elf_Rel); j++) { in read_relocs()
310 for (j = 0; j < sec->shdr.sh_size / sizeof(Elf_Rel); j++) { in walk_relocs()
/linux-6.12.1/arch/arm/kernel/
Dmodule.c85 for (i = 0; i < relsec->sh_size / sizeof(Elf32_Rel); i++, rel++) { in apply_relocate()
99 if (offset < 0 || offset > (symsec->sh_size / sizeof(Elf32_Sym))) { in apply_relocate()
108 if (rel->r_offset < 0 || rel->r_offset > dstsec->sh_size - sizeof(u32)) { in apply_relocate()
111 rel->r_offset, dstsec->sh_size); in apply_relocate()
444 s->sh_size, in module_finalize()
446 txt_sec->sh_size); in module_finalize()
459 fixup_pv_table((void *)s->sh_addr, s->sh_size); in module_finalize()
464 fixup_smp((void *)s->sh_addr, s->sh_size); in module_finalize()
Dmodule-plts.c83 BUG_ON(pltsec->plt_count * PLT_ENT_SIZE > pltsec->plt->sh_size); in get_module_plt()
241 int numrels = s->sh_size / sizeof(Elf32_Rel); in module_frob_arch_sections()
265 mod->arch.core.plt->sh_size = round_up(core_plts * PLT_ENT_SIZE, in module_frob_arch_sections()
273 mod->arch.init.plt->sh_size = round_up(init_plts * PLT_ENT_SIZE, in module_frob_arch_sections()
279 mod->arch.core.plt->sh_size, mod->arch.init.plt->sh_size); in module_frob_arch_sections()
/linux-6.12.1/arch/loongarch/kernel/
Dmodule-sections.c139 int num_rela = sechdrs[i].sh_size / sizeof(Elf_Rela); in module_frob_arch_sections()
157 got_sec->sh_size = (num_gots + 1) * sizeof(struct got_entry); in module_frob_arch_sections()
165 plt_sec->sh_size = (num_plts + 1) * sizeof(struct plt_entry); in module_frob_arch_sections()
173 plt_idx_sec->sh_size = (num_plts + 1) * sizeof(struct plt_idx_entry); in module_frob_arch_sections()
181 tramp->sh_size = NR_FTRACE_PLTS * sizeof(struct plt_entry); in module_frob_arch_sections()
/linux-6.12.1/scripts/
Drecordmcount.h214 return w(shdr0->sh_size); in get_shnum()
223 shdr0->sh_size = w(new_shnum); in set_shnum()
273 uint_t const old_shstr_sh_size = _w(shstr->sh_size); in append_func()
278 uint_t t = 1 + strlen(mc_name) + _w(shstr->sh_size); in append_func()
281 shstr->sh_size = _w(t); in append_func()
313 mcsec.sh_size = _w((void *)mlocp - (void *)mloc0); in append_func()
328 mcsec.sh_size = _w((void *)mrelp - (void *)mrel0); in append_func()
415 unsigned const nrel = _w(relhdr->sh_size) / rel_entsize; in sift_rel_mcount()
462 unsigned const nrel = _w(relhdr->sh_size) / rel_entsize; in nop_mcount()
527 unsigned const nsym = _w(symhdr->sh_size) / _w(symhdr->sh_entsize); in find_secsym_ndx()
[all …]
Dsorttable.h304 shnum = _r(&shdr[0].sh_size); in do_sort()
321 relocs_size = _r(&s->sh_size); in do_sort()
341 orc_ip_size = s->sh_size; in do_sort()
346 orc_size = s->sh_size; in do_sort()
417 custom_sort(extab_image, _r(&extab_sec->sh_size)); in do_sort()
419 int num_entries = _r(&extab_sec->sh_size) / extable_ent_size; in do_sort()
430 sym < sym + _r(&symtab_sec->sh_size) / sizeof(Elf_Sym); in do_sort()
Dinsert-sys-cert.c75 num_sections = x[0].sh_size; in get_offset_from_address()
81 unsigned long end = start + x[i].sh_size; in get_offset_from_address()
144 n = symtab->sh_size / symtab->sh_entsize; in find_elf_symbol()
191 num_sections = x[0].sh_size; in get_symbol_table()
/linux-6.12.1/arch/sparc/kernel/
Dmodule.c44 for (i = 1; i < sechdrs[symidx].sh_size / sizeof(Elf_Sym); i++) { in module_frob_arch_sections()
65 for (i = 0; i < sechdrs[relsec].sh_size / sizeof(*rel); i++) { in apply_relocate_add()
169 sun4v_patch_1insn_range(p, p + sun4v_1insn->sh_size); in do_patch_sections()
173 sun4v_patch_2insn_range(p, p + sun4v_2insn->sh_size); in do_patch_sections()
/linux-6.12.1/arch/alpha/kernel/
Dmodule.c95 nsyms = symtab->sh_size / sizeof(Elf64_Sym); in module_frob_arch_sections()
104 got->sh_size = 0; in module_frob_arch_sections()
112 nrela = s->sh_size / sizeof(Elf64_Rela); in module_frob_arch_sections()
116 &got->sh_size); in module_frob_arch_sections()
138 unsigned long i, n = sechdrs[relsec].sh_size / sizeof(*rela); in apply_relocate_add()
/linux-6.12.1/arch/riscv/kernel/
Dmodule-sections.c125 int num_rela = sechdrs[i].sh_size / sizeof(Elf_Rela); in module_frob_arch_sections()
141 mod->arch.plt.shdr->sh_size = (num_plts + 1) * sizeof(struct plt_entry); in module_frob_arch_sections()
148 mod->arch.got.shdr->sh_size = (num_gots + 1) * sizeof(struct got_entry); in module_frob_arch_sections()
155 mod->arch.got_plt.shdr->sh_size = (num_plts + 1) * sizeof(struct got_entry); in module_frob_arch_sections()
/linux-6.12.1/drivers/remoteproc/
Dremoteproc_elf_loader.c376 u64 sh_addr, sh_size; local
385 sh_size = elf_shdr_get_sh_size(class, shdr);
387 if (!rproc_u64_fit_in_size_t(sh_size)) {
389 sh_size);
393 return rproc_da_to_va(rproc, sh_addr, sh_size, NULL);
/linux-6.12.1/arch/x86/entry/vdso/
Dvdso2c.h33 len = (size_t)GET_LE(&sec->sh_size); in BITSFUNC()
125 syms_nr = GET_LE(&symtab_hdr->sh_size) / GET_LE(&symtab_hdr->sh_entsize); in BITSFUNC()
207 (unsigned long)GET_LE(&alt_sec->sh_size)); in BITSFUNC()
213 (unsigned long)GET_LE(&extable_sec->sh_size)); in BITSFUNC()
/linux-6.12.1/arch/s390/kernel/
Dmodule.c130 me->arch.nsyms = symtab->sh_size / sizeof(Elf_Sym); in module_frob_arch_sections()
154 nrela = sechdrs[i].sh_size / sizeof(Elf_Rela); in module_frob_arch_sections()
443 n = sechdrs[relsec].sh_size / sizeof(Elf_Rela); in __apply_relocate_add()
475 size = FTRACE_HOTPATCH_TRAMPOLINES_SIZE(s->sh_size); in module_alloc_ftrace_hotpatch_trampolines()
520 apply_alternatives(aseg, aseg + s->sh_size); in module_finalize()
524 nospec_revert(aseg, aseg + s->sh_size); in module_finalize()
528 nospec_revert(aseg, aseg + s->sh_size); in module_finalize()
/linux-6.12.1/tools/lib/bpf/
Dlinker.c286 symtab->shdr->sh_size += sizeof(*sym); in add_new_sym()
376 sec->shdr->sh_size = sec->sec_sz = 0; in init_output_elf()
493 if (shdr->sh_type == SHT_PROGBITS && shdr->sh_size == 0 && in is_ignored_sec()
656 obj->btf = btf__new(data->d_buf, shdr->sh_size); in linker_load_obj_file()
666 obj->btf_ext = btf_ext__new(data->d_buf, shdr->sh_size); in linker_load_obj_file()
738 if (sec->shdr->sh_size != sec->data->d_size) { in linker_sanity_check_elf()
740 sec->sec_idx, (long long unsigned)sec->shdr->sh_size, in linker_sanity_check_elf()
755 if (sec->shdr->sh_size % sizeof(struct bpf_insn) != 0) { in linker_sanity_check_elf()
757 sec->sec_idx, (long long unsigned)sec->shdr->sh_size, in linker_sanity_check_elf()
790 if (sec->shdr->sh_size % sec->shdr->sh_entsize != 0) in linker_sanity_check_elf_symtab()
[all …]
/linux-6.12.1/arch/mips/kernel/
Dvpe.c174 *size = ret + sechdr->sh_size; in get_offset()
437 for (i = 0; i < sechdrs[relsec].sh_size / sizeof(*rel); i++) { in apply_relocations()
484 unsigned int i, n = sechdrs[symindex].sh_size / sizeof(Elf_Sym); in simplify_symbols()
539 unsigned int i, n = sechdrs[symindex].sh_size / sizeof(Elf_Sym); in dump_elfsymbols()
554 unsigned int i, n = sechdrs[symindex].sh_size / sizeof(Elf_Sym); in find_vpe_symbols()
621 (len < sechdrs[i].sh_offset + sechdrs[i].sh_size)) { in vpe_elfload()
660 sechdrs[i].sh_size); in vpe_elfload()
/linux-6.12.1/arch/arm64/kernel/
Dmodule-plts.c316 int nents, numrels = sechdrs[i].sh_size / sizeof(Elf64_Rela); in module_frob_arch_sections()
347 pltsec->sh_size = (core_plts + 1) * sizeof(struct plt_entry); in module_frob_arch_sections()
355 pltsec->sh_size = (init_plts + 1) * sizeof(struct plt_entry); in module_frob_arch_sections()
363 tramp->sh_size = NR_FTRACE_PLTS * sizeof(struct plt_entry); in module_frob_arch_sections()
/linux-6.12.1/arch/m68k/kernel/
Dmodule.c35 for (i = 0; i < sechdrs[relsec].sh_size / sizeof(*rel); i++) { in apply_relocate()
75 for (i = 0; i < sechdrs[relsec].sh_size / sizeof(*rel); i++) { in apply_relocate_add()
/linux-6.12.1/arch/arc/kernel/
Dmodule.c64 n = sechdrs[relsec].sh_size / sizeof(*rel_entry); in apply_relocate_add()
141 sechdrs[unwsec].sh_size); in module_finalize()
/linux-6.12.1/arch/mips/vdso/
Dgenvdso.h51 shdr->sh_entsize = shdr->sh_size; in FUNC()
98 st_count = FUNC(swap_uint)(shdr->sh_size) / st_entsize; in FUNC()

1234