|
PatchworkOS
|
Executable and linkable format definitions. More...
Data Structures | |
| struct | elf_hdr_t |
| ELF file header. More... | |
| struct | elf_phdr_t |
| ELF program header. More... | |
| struct | elf_shdr_t |
| ELF section header. More... | |
| struct | elf_sym_t |
| ELF symbol table entry. More... | |
| struct | elf_rela_t |
| ELF relocation entry with addend. More... | |
| struct | elf_rel_t |
| ELF relocation entry without addend. More... | |
| struct | elf_dyn_t |
| ELF dynamic entry. More... | |
| struct | elf_note_t |
| ELF note header. More... | |
Typedefs | |
| typedef uint16_t | elf_hdr_type_t |
| typedef uint16_t | elf_hdr_machine_t |
| typedef uint32_t | elf_hdr_version_t |
| typedef uint32_t | elf_phdr_type_t |
| typedef uint32_t | elf_phdr_flags_t |
| typedef uint32_t | elf_shdr_type_t |
| typedef uint64_t | elf_shdr_flags_t |
Executable and linkable format definitions.
The sys/elf.h header defines structs and constants for ELF files used in Patchwork, note that Patchwork only supports ELF files.
| #define ELF_IS_VALID | ( | hdr | ) |
Checks the validity of an ELF header.
The ELF_IS_VALID() macro checks that the ELF file header is using version 1, 64-bit, x86_64 with little endian and System V ABI.
| hdr | A pointer to the ELF header structure. |
| #define ELF_PHDR_TYPE_GNU_EH_FRAME (ELF_PHDR_TYPE_LOW_OS + 0x474e550) |
| #define ELF_PHDR_TYPE_GNU_PROPERTY (ELF_PHDR_TYPE_LOW_OS + 0x474e553) |
| #define ELF_PHDR_TYPE_GNU_RELRO (ELF_PHDR_TYPE_LOW_OS + 0x474e552) |
| #define ELF_PHDR_TYPE_GNU_STACK (ELF_PHDR_TYPE_LOW_OS + 0x474e551) |
| typedef uint16_t elf_hdr_machine_t |
| typedef uint16_t elf_hdr_type_t |
| typedef uint32_t elf_hdr_version_t |
| typedef uint32_t elf_phdr_flags_t |
| typedef uint32_t elf_phdr_type_t |
| typedef uint64_t elf_shdr_flags_t |
| typedef uint32_t elf_shdr_type_t |