Lines Matching refs:ehdr
517 GElf_Ehdr ehdr;
518 if (unlikely (gelf_getehdr (mod->main.elf, &ehdr) == NULL))
526 if (ehdr.e_entry == 0)
531 if (ehdr.e_entry != at_entry)
561 && (phdr->p_offset & -align) == (ehdr.e_phoff & -align))
568 if (ehdr.e_phoff - phdr->p_offset + phdr->p_vaddr != at_phdr)
576 if (((ehdr.e_phoff - phdr->p_offset + phdr->p_vaddr) & -align)
581 GElf_Addr bias = (at_phdr - (ehdr.e_phoff - phdr->p_offset
586 if (at_entry != 0 && at_entry != ehdr.e_entry + bias)
633 size_t buffer_available = addrsize (ehdr.e_ident[EI_CLASS]);
649 if (ehdr.e_ident[EI_CLASS] == ELFCLASS32)
650 vaddr = (ehdr.e_ident[EI_DATA] == ELFDATA2MSB
653 vaddr = (ehdr.e_ident[EI_DATA] == ELFDATA2MSB
660 *elfclass = ehdr.e_ident[EI_CLASS];
661 else if (*elfclass != ehdr.e_ident[EI_CLASS])
665 *elfdata = ehdr.e_ident[EI_DATA];
666 else if (*elfdata != ehdr.e_ident[EI_DATA])
825 GElf_Ehdr ehdr_mem, *ehdr = gelf_getehdr (elf, &ehdr_mem);
826 if (ehdr == NULL)
841 if (e_phnum != phnum || ehdr->e_phentsize != phent)
848 off_t off = ehdr->e_phoff;