Fix handling of EFI with big memory maps.
* grub-core/loader/i386/linux.c (GRUB_LINUX_CL_OFFSET): Removed. (real_mode_mem): Likewise. (real_mode_target): Likewise. (real_mode_pages): Likewise. (prot_mode_pages): Likewise. (linux_params): New var. (linux_cmdline): Likewise. (free_pages): Don't set real mode variables. (allocate_pages): Don't allocate real mode memory. (grub_e820_add_region): Remove the limit. (grub_linux_boot): Allocate and copy real mode memory. (grub_linux_unload): Free linux_cmdline. (grub_cmd_linux): Use temporary storage for parameters. (grub_cmd_initrd): Likewise. * include/grub/i386/linux.h (GRUB_E820_MAX_ENTRY): Removed. (linux_kernel_params): Make it 1K big.
This commit is contained in:
parent
ddb7355862
commit
a4e5ca80d9
3 changed files with 120 additions and 106 deletions
|
@ -69,8 +69,6 @@
|
|||
#define GRUB_E820_NVS 4
|
||||
#define GRUB_E820_BADRAM 5
|
||||
|
||||
#define GRUB_E820_MAX_ENTRY 128
|
||||
|
||||
struct grub_e820_mmap
|
||||
{
|
||||
grub_uint64_t addr;
|
||||
|
@ -298,7 +296,7 @@ struct linux_kernel_params
|
|||
grub_uint32_t payload_length;
|
||||
grub_uint64_t setup_data;
|
||||
grub_uint8_t pad2[120]; /* 258 */
|
||||
struct grub_e820_mmap e820_map[GRUB_E820_MAX_ENTRY]; /* 2d0 */
|
||||
struct grub_e820_mmap e820_map[(0x400 - 0x2d0) / 20]; /* 2d0 */
|
||||
|
||||
} __attribute__ ((packed));
|
||||
#endif /* ! ASM_FILE */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue