Lines Matching refs:elf_ex
461 static struct elf_phdr *load_elf_phdrs(const struct elfhdr *elf_ex, in load_elf_phdrs() argument
472 if (elf_ex->e_phentsize != sizeof(struct elf_phdr)) in load_elf_phdrs()
477 size = sizeof(struct elf_phdr) * elf_ex->e_phnum; in load_elf_phdrs()
486 retval = elf_read(elf_file, elf_phdata, size, elf_ex->e_phoff); in load_elf_phdrs()
841 struct elfhdr *elf_ex = (struct elfhdr *)bprm->buf; in load_elf_binary() local
849 if (memcmp(elf_ex->e_ident, ELFMAG, SELFMAG) != 0) in load_elf_binary()
852 if (elf_ex->e_type != ET_EXEC && elf_ex->e_type != ET_DYN) in load_elf_binary()
854 if (!elf_check_arch(elf_ex)) in load_elf_binary()
856 if (elf_check_fdpic(elf_ex)) in load_elf_binary()
861 elf_phdata = load_elf_phdrs(elf_ex, bprm->file); in load_elf_binary()
866 for (i = 0; i < elf_ex->e_phnum; i++, elf_ppnt++) { in load_elf_binary()
931 for (i = 0; i < elf_ex->e_phnum; i++, elf_ppnt++) in load_elf_binary()
941 retval = arch_elf_pt_proc(elf_ex, elf_ppnt, in load_elf_binary()
995 retval = arch_check_elf(elf_ex, in load_elf_binary()
1008 SET_PERSONALITY2(*elf_ex, &arch_state); in load_elf_binary()
1009 if (elf_read_implies_exec(*elf_ex, executable_stack)) in load_elf_binary()
1035 i < elf_ex->e_phnum; i++, elf_ppnt++) { in load_elf_binary()
1085 } else if (elf_ex->e_type == ET_EXEC) { in load_elf_binary()
1092 } else if (elf_ex->e_type == ET_DYN) { in load_elf_binary()
1124 alignment = maximum_alignment(elf_phdata, elf_ex->e_phnum); in load_elf_binary()
1159 elf_ex->e_phnum); in load_elf_binary()
1176 if (elf_ex->e_type == ET_DYN) { in load_elf_binary()
1187 if (elf_ppnt->p_offset <= elf_ex->e_phoff && in load_elf_binary()
1188 elf_ex->e_phoff < elf_ppnt->p_offset + elf_ppnt->p_filesz) { in load_elf_binary()
1189 phdr_addr = elf_ex->e_phoff - elf_ppnt->p_offset + in load_elf_binary()
1227 e_entry = elf_ex->e_entry + load_bias; in load_elf_binary()
1287 retval = ARCH_SETUP_ADDITIONAL_PAGES(bprm, elf_ex, !!interpreter); in load_elf_binary()
1292 retval = create_elf_tables(bprm, elf_ex, interp_load_addr, in load_elf_binary()
1313 elf_ex->e_type == ET_DYN && !interpreter) { in load_elf_binary()
1348 START_THREAD(elf_ex, regs, elf_entry, bprm->p); in load_elf_binary()
1375 struct elfhdr elf_ex; in load_elf_library() local
1378 retval = elf_read(file, &elf_ex, sizeof(elf_ex), 0); in load_elf_library()
1382 if (memcmp(elf_ex.e_ident, ELFMAG, SELFMAG) != 0) in load_elf_library()
1386 if (elf_ex.e_type != ET_EXEC || elf_ex.e_phnum > 2 || in load_elf_library()
1387 !elf_check_arch(&elf_ex) || !file->f_op->mmap) in load_elf_library()
1389 if (elf_check_fdpic(&elf_ex)) in load_elf_library()
1394 j = sizeof(struct elf_phdr) * elf_ex.e_phnum; in load_elf_library()
1404 retval = elf_read(file, eppnt, j, elf_ex.e_phoff); in load_elf_library()
1408 for (j = 0, i = 0; i<elf_ex.e_phnum; i++) in load_elf_library()