diff options
author | Ronald G. Minnich <rminnich@google.com> | 2016-09-28 10:43:12 -0700 |
---|---|---|
committer | Ronald G. Minnich <rminnich@gmail.com> | 2016-09-28 23:05:00 +0200 |
commit | fa74e4705dbb5ecf5ba466fd6a9bc309f7e3e8bf (patch) | |
tree | cbbc9a8dfe6e49b6d9c8d85892bf80497044a815 /util/cbfstool/linux.h | |
parent | 6d16e1ff87f31ff558cea76741f5675763d4ab44 (diff) | |
download | coreboot-fa74e4705dbb5ecf5ba466fd6a9bc309f7e3e8bf.tar.xz |
cbfstool: set init_size for linux payloads.
We were not setting the init_size for linux payloads.
A proper value of init_size is required if the kernel
is x86_64.
This is tested in qemu and fixes the observed problem
that 974f221c84b05b1dc2f5ea50dc16d2a9d1e95eda and later would not
boot, and would in fact fail in head_64.S.
Change-Id: I254c13d16b1e014a6f1d4fd7c39b1cfe005cd9b0
Signed-off-by: Ronald G. Minnich <rminnich@google.com>
Reviewed-on: https://review.coreboot.org/16781
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Patrick Georgi <pgeorgi@google.com>
Tested-by: build bot (Jenkins)
Diffstat (limited to 'util/cbfstool/linux.h')
-rw-r--r-- | util/cbfstool/linux.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/util/cbfstool/linux.h b/util/cbfstool/linux.h index b96f447a07..2fd2d4d32a 100644 --- a/util/cbfstool/linux.h +++ b/util/cbfstool/linux.h @@ -139,7 +139,13 @@ struct linux_params { u32 alt_mem_k; /* 0x1e0 */ u8 reserved5[4]; /* 0x1e4 */ u8 e820_map_nr; /* 0x1e8 */ - u8 reserved6[9]; /* 0x1e9 */ + u8 reserved6[8]; /* 0x1e9 */ + /* This next variable is to show where + * in this struct the Linux setup_hdr + * is located. It does not get filled in. + * We may someday find it useful to use + * its address. */ + u8 setup_hdr; /* 0x1f1 */ u16 mount_root_rdonly; /* 0x1f2 */ u8 reserved7[4]; /* 0x1f4 */ u16 ramdisk_flags; /* 0x1f8 */ @@ -170,7 +176,9 @@ struct linux_params { u32 initrd_addr_max; /* 0x22c */ u32 kernel_alignment; /* 0x230 */ u8 relocatable_kernel; /* 0x234 */ - u8 reserved13[155]; /* 0x22c */ + u8 reserved13[0x2b]; /* 0x235 */ + u32 init_size; /* 0x260 */ + u8 reserved14[0x6c]; /* 0x264 */ struct e820entry e820_map[E820MAX]; /* 0x2d0 */ u8 reserved16[688]; /* 0x550 */ #define COMMAND_LINE_SIZE 256 |