arch: x86: Always set the bootloader type
We set it to 0xff, which is for unregistered loaders. The kernel checks that the bootloader ID is set when e.g. loading ramdisks, so not setting it when we get a bootparams header from the loader will prevent the kernel from loading ramdisks. Fixes: #918 Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
This commit is contained in:
parent
ad354700c9
commit
9cf67d133f
1 changed files with 3 additions and 1 deletions
|
|
@ -307,13 +307,15 @@ fn configure_64bit_boot(
|
|||
// We should use the header if the loader provides one (e.g. from a bzImage).
|
||||
params.0.hdr = hdr;
|
||||
} else {
|
||||
params.0.hdr.type_of_loader = KERNEL_LOADER_OTHER;
|
||||
params.0.hdr.boot_flag = KERNEL_BOOT_FLAG_MAGIC;
|
||||
params.0.hdr.header = KERNEL_HDR_MAGIC;
|
||||
params.0.hdr.kernel_alignment = KERNEL_MIN_ALIGNMENT_BYTES;
|
||||
};
|
||||
|
||||
// Common bootparams settings
|
||||
if params.0.hdr.type_of_loader == 0 {
|
||||
params.0.hdr.type_of_loader = KERNEL_LOADER_OTHER;
|
||||
}
|
||||
params.0.hdr.cmd_line_ptr = cmdline_addr.raw_value() as u32;
|
||||
params.0.hdr.cmdline_size = cmdline_size as u32;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue