Lines Matching refs:ehdr
475 Elf32_Ehdr *ehdr; in do_file() local
478 ehdr = mmap_file(fname); in do_file()
479 if (!ehdr) in do_file()
485 switch (ehdr->e_ident[EI_DATA]) { in do_file()
489 ehdr->e_ident[EI_DATA], fname); in do_file()
518 if (memcmp(ELFMAG, ehdr->e_ident, SELFMAG) != 0 || in do_file()
519 w2(ehdr->e_type) != ET_REL || in do_file()
520 ehdr->e_ident[EI_VERSION] != EV_CURRENT) { in do_file()
526 switch (w2(ehdr->e_machine)) { in do_file()
529 w2(ehdr->e_machine), fname); in do_file()
570 switch (ehdr->e_ident[EI_CLASS]) { in do_file()
573 ehdr->e_ident[EI_CLASS], fname); in do_file()
576 if (w2(ehdr->e_ehsize) != sizeof(Elf32_Ehdr) in do_file()
577 || w2(ehdr->e_shentsize) != sizeof(Elf32_Shdr)) { in do_file()
582 if (w2(ehdr->e_machine) == EM_MIPS) { in do_file()
586 if (do32(ehdr, fname, reltype) < 0) in do_file()
590 Elf64_Ehdr *const ghdr = (Elf64_Ehdr *)ehdr; in do_file()