Crate kernel_loader
source ·Expand description
Linux kernel ELF file loader.
Modules§
- arm64 🔒Linux arm64 kernel loader. https://www.kernel.org/doc/Documentation/arm64/booting.txt
- elf 🔒
- Multiboot kernel loader
Structs§
Enums§
Functions§
- Loads a kernel from a 32-bit or 64-bit ELF image into memory.
- Loads a kernel from a 32-bit ELF image into memory.
- Loads a kernel from a 64-bit ELF image into memory.
- Load a Multiboot kernel image into memory.
- Scan the provided kernel file to find a Multiboot header, if present.
- read_elf 🔒Reads the headers of an ELF32 or ELF64 object file. Returns ELF file and program headers, converted to ELF64 format. If
required_ei_class
is Some and the file’s ELF ei_class doesn’t match, an Err is returned. - Reads the headers of an ELF32 or ELF64 object file. Returns ELF file and program headers, converted to ELF64 format.
FileHeader
andProgramHeader
are the ELF32 or ELF64 ehdr/phdr types to read from the file. Caller should check thatfile
is a valid ELF file before calling this function.