2 * Copyright (C) 2001-2003 Hewlett-Packard Co.
3 * Contributed by Stephane Eranian <eranian@hpl.hp.com>
4 * Contributed by Mike Johnston <johnston@intel.com>
5 * Contributed by Chris Ahna <christopher.j.ahna@intel.com>
7 * This file is part of the ELILO, the EFI Linux boot loader.
9 * ELILO is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2, or (at your option)
14 * ELILO is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17 * GNU General Public License for more details.
19 * You should have received a copy of the GNU General Public License
20 * along with ELILO; see the file COPYING. If not, write to the Free
21 * Software Foundation, 59 Temple Place - Suite 330, Boston, MA
24 * Please check out the elilo.txt for complete documentation on how
25 * to use this program.
29 * this file contains all the IA-32 specific code expected by generic loader
39 /* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = */
40 /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
42 /* extern loader_ops_t plain_loader, gzip_loader; */
44 efi_ia32_boot_params_t efi_ia32_bp;
48 * Descriptor table base addresses & limits for Linux startup.
51 dt_addr_t gdt_addr = { 0x800, 0x94000 };
52 dt_addr_t idt_addr = { 0, 0 };
55 * Initial GDT layout for Linux startup.
66 0xFFFF, /* 4Gb - (0x100000*0x1000 = 4Gb) */
67 0x0000, /* base address=0 */
68 0x9A00, /* code read/exec */
69 0x00CF, /* granularity=4096, 386 (+5th nibble of limit) */
72 0xFFFF, /* 4Gb - (0x100000*0x1000 = 4Gb) */
73 0x0000, /* base address=0 */
74 0x9200, /* data read/write */
75 0x00CF, /* granularity=4096, 386 (+5th nibble of limit) */
78 UINTN sizeof_init_gdt = sizeof init_gdt;
82 * Highest available base memory address.
84 * For traditional kernels and loaders this is always at 0x90000.
85 * For updated kernels and loaders this is computed by taking the
86 * highest available base memory address and rounding down to the
87 * nearest 64 kB boundary and then subtracting 64 kB.
89 * A non-compressed kernel is automatically assumed to be an updated
90 * kernel. A compressed kernel that has bit 6 (0x40) set in the
91 * loader_flags field is also assumed to be an updated kernel.
94 UINTN high_base_mem = 0x90000;
97 * Highest available extended memory address.
99 * This is computed by taking the highest available extended memory
100 * address and rounding down to the nearest EFI_PAGE_SIZE (usually
101 * 4 kB) boundary. The ia32 Linux kernel can only support up to
105 UINTN high_ext_mem = 32 * 1024 * 1024;
108 * Starting location and size of runtime memory blocks.
111 boot_params_t *param_start = NULL;
112 UINTN param_size = 0;
114 VOID *kernel_start = (VOID *)0x100000; /* 1M */
115 UINTN kernel_size = 0x200000; /* 2M (largest x86 kernel image) */
117 VOID *initrd_start = NULL;
118 UINTN initrd_size = 0;
121 * Boot parameters can be relocated if TRUE.
122 * Boot parameters must be placed at 0x90000 if FALSE.
124 * This will be set to TRUE if bit 6 (0x40) is set in the loader_flags
125 * field in a compressed x86 boot format kernel. This will also be set
126 * to TRUE if the kernel is an uncompressed ELF32 image.
128 * To remote boot w/ the universal network driver and a 16-bit UNDI
129 * this must be set to TRUE.
132 BOOLEAN can_reloc_boot_params = FALSE;
134 /* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = */
135 /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
137 probe_bzImage_boot(CHAR16 *kname)
139 EFI_STATUS efi_status;
144 DBG_PRT((L"probe_bzImage_boot()\n"));
147 ERR_PRT((L"kname == %xh", kname));
156 DBG_PRT((L"opening %s...\n", kname));
158 efi_status = fops_open(kname, &fd);
160 if (EFI_ERROR(efi_status)) {
161 ERR_PRT((L"Could not open %s.", kname));
170 DBG_PRT((L"\nreading boot sector...\n"));
172 size = sizeof bootsect;
173 efi_status = fops_read(fd, bootsect, &size);
175 if (EFI_ERROR(efi_status) || size != sizeof bootsect) {
176 ERR_PRT((L"Could not read boot sector from %s.", kname));
183 * Verify boot sector signature.
186 if (bootsect[0x1FE] != 0x55 || bootsect[0x1FF] != 0xAA) {
187 ERR_PRT((L"%s is not a bzImage kernel image.\n", kname));
194 * Check for out of range setup data size.
195 * Will almost always be 7, but we will accept 1 to 64.
198 DBG_PRT((L"bootsect[1F1h] == %d setup sectors\n", bootsect[0x1F1]));
200 if (bootsect[0x1F1] < 1 || bootsect[0x1F1] > 64) {
201 ERR_PRT((L"%s is not a valid bzImage kernel image.",
210 * Allocate and read setup data.
213 DBG_PRT((L"reading setup data...\n"));
215 param_size = (bootsect[0x1F1] + 1) * 512;
216 //param_start = alloc(param_size, EfiBootServicesData);
217 param_start = alloc(param_size, EfiLoaderData);
219 DBG_PRT((L"param_size=%d param_start=%x", param_size, param_start));
222 ERR_PRT((L"Could not allocate %d bytes of setup data.",
230 CopyMem(param_start, bootsect, sizeof bootsect);
232 size = param_size - 512;
233 efi_status = fops_read(fd, ((UINT8 *)param_start) + 512, &size);
235 if (EFI_ERROR(efi_status) || size != param_size - 512) {
236 ERR_PRT((L"Could not read %d bytes of setup data.",
248 * Check for setup data signature.
251 { UINT8 *c = ((UINT8 *)param_start)+514;
252 DBG_PRT((L"param_start(c=%x): %c-%c-%c-%c", c, (CHAR16)c[0],(CHAR16) c[1], (CHAR16)c[2], (CHAR16)c[3]));
254 if (CompareMem(((UINT8 *)param_start) + 514, "HdrS", 4)) {
255 ERR_PRT((L"%s does not have a setup signature.",
267 * Allocate memory for kernel.
270 if (alloc_kmem(kernel_start, EFI_SIZE_TO_PAGES(kernel_size))) {
271 ERR_PRT((L"Could not allocate kernel memory."));
274 VERB_PRT(3, Print(L"kernel_start: 0x%x kernel_size: %d\n", kernel_start, kernel_size));
278 * Now read the rest of the kernel image into memory.
281 DBG_PRT((L"reading kernel image...\n"));
285 efi_status = fops_read(fd, kernel_start, &size);
287 if (EFI_ERROR(efi_status) || size < 0x10000) {
288 ERR_PRT((L"Error reading kernel image %s.", kname));
297 DBG_PRT((L"kernel image read: %d bytes, %d Kbytes\n", size, size / 1024));
300 * Boot sector, setup data and kernel image loaded.
307 /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
309 load_bzImage_boot(CHAR16 *kname, kdesc_t *kd)
311 DBG_PRT((L"load_bzImage_boot()\n"));
314 ERR_PRT((L"kname=0x%x kd=0x%x", kname, kd));
323 kd->kstart = kd->kentry = kernel_start;
324 kd->kend = ((UINT8 *)kd->kstart) + kernel_size;
326 DBG_PRT((L"kstart=0x%x kentry=0x%x kend=0x%x\n", kd->kstart, kd->kentry, kd->kend));
331 /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
332 static loader_ops_t loader_bzImage_boot = {
334 L"loader_bzImage_boot",
339 /* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = */
340 /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
342 sysdeps_init(EFI_HANDLE dev)
345 DBG_PRT((L"sysdeps_init()\n"));
348 * Register our loader(s)...
351 loader_register(&loader_bzImage_boot);
352 /* loader_register(&plain_loader); */
353 /* loader_register(&gzip_loader); */
359 /* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = */
360 /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
363 * Compute a starting address for the initial RAMdisk image.
364 * For now, this image is placed immediately after the end of
365 * the kernel memory. Inside the start_kernel() code, the
366 * RAMdisk image will be relocated to the top of available
370 sysdeps_initrd_get_addr(kdesc_t *kd, memdesc_t *imem)
372 DBG_PRT((L"initrd_get_addr()\n"));
375 ERR_PRT((L"kd=0x%x imem=0x%x", kd, imem));
379 VERB_PRT(3, Print(L"kstart=0x%x kentry=0x%x kend=0x%x\n",
380 kd->kstart, kd->kentry, kd->kend));
382 imem->start_addr = kd->kend;
384 VERB_PRT(3, Print(L"initrd start_addr=0x%x pgcnt=%d\n", imem->start_addr, imem->pgcnt));
389 /* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = */
390 /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
392 sysdeps_free_boot_params(boot_params_t *bp)
396 ZeroMem(&md, sizeof md);
397 md.md = (VOID *)bp->s.efi_mem_map;
401 /* = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = */
402 /* - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
404 * IA-32 specific boot parameters initialization routine
407 sysdeps_create_boot_params(
414 EFI_STATUS efi_status;
420 DBG_PRT((L"fill_boot_params()\n"));
422 if (!bp || !cmdline || !initrd || !cookie) {
423 ERR_PRT((L"bp=0x%x cmdline=0x%x initrd=0x%x cookie=0x%x",
424 bp, cmdline, initrd, cookie));
434 * Copy temporary boot sector and setup data storage to
435 * elilo allocated boot parameter storage. We only need
436 * the first two sectors (1K). The rest of the storage
437 * can be used by the command line.
440 CopyMem(bp, param_start, 0x2000);
447 * Save off our header revision information.
450 hdr_version = (bp->s.hdr_major << 8) | bp->s.hdr_minor;
453 * Clear out unused memory in boot sector image.
458 ZeroMem(bp->s.unused_3, sizeof bp->s.unused_3);
459 ZeroMem(bp->s.unused_4, sizeof bp->s.unused_4);
460 ZeroMem(bp->s.unused_5, sizeof bp->s.unused_5);
464 * Tell kernel this was loaded by an advanced loader type.
465 * If this field is zero, the initrd_start and initrd_size
466 * fields are ignored by the kernel.
469 bp->s.loader_type = LDRTYPE_ELILO;
472 * Setup command line information.
475 bp->s.cmdline_magik = CMDLINE_MAGIK;
476 bp->s.cmdline_offset = (UINT8 *)cmdline - (UINT8 *)bp;
479 * Setup hard drive parameters.
480 * %%TBD - It should be okay to zero fill the hard drive
481 * info buffers. The kernel should do its own detection.
484 ZeroMem(bp->s.hd0_info, sizeof bp->s.hd0_info);
485 ZeroMem(bp->s.hd1_info, sizeof bp->s.hd1_info);
488 CopyMem(bp->s.hd0_info, *((VOID **)(0x41 * 4)),
489 sizeof bp->s.hd0_info);
491 CopyMem(bp->s.hd1_info, *((VOID **)(0x46 * 4)),
492 sizeof bp->s.hd1_info);
499 bp->s.alt_mem_k = high_ext_mem / 1024;
501 if (bp->s.alt_mem_k <= 65535) {
502 bp->s.ext_mem_k = (UINT16)bp->s.alt_mem_k;
504 bp->s.ext_mem_k = 65535;
507 if (hdr_version < 0x0202)
508 bp->s.base_mem_size = high_base_mem;
511 * Initial RAMdisk and root device stuff.
514 DBG_PRT((L"initrd->start_addr=0x%x initrd->pgcnt=%d\n",
515 initrd->start_addr, initrd->pgcnt));
517 /* These RAMdisk flags are not needed, just zero them. */
518 bp->s.ramdisk_flags = 0;
520 if (initrd->start_addr && initrd->pgcnt) {
521 /* %%TBD - This will probably have to be changed. */
522 bp->s.initrd_start = (UINT32)initrd->start_addr;
523 bp->s.initrd_size = (UINT32)(initrd->pgcnt * EFI_PAGE_SIZE);
526 * This is the RAMdisk root device for RedHat 2.2.x
527 * kernels (major 0x01, minor 0x00).
528 * %%TBD - Will this work for other distributions and
529 * 2.3.x and 2.4.x kernels? I do not know, yet.
532 bp->s.orig_root_dev = 0x0100;
534 bp->s.initrd_start = 0;
535 bp->s.initrd_size = 0;
537 /* Do not change the root device if there is no RAMdisk. */
538 /* bp->s.orig_root_dev = 0; */
545 /* %%TBD - How to do Int 15h calls to get this info? */
546 bp->s.apm_bios_ver = NO_APM_BIOS;
547 bp->s.bios_code_seg = 0;
548 bp->s.bios_entry_point = 0;
549 bp->s.bios_code_seg16 = 0;
550 bp->s.bios_data_seg = 0;
551 bp->s.apm_bios_flags = 0;
552 bp->s.bios_code_len = 0;
553 bp->s.bios_data_len = 0;
556 * MCA BIOS info (misnomer).
559 /* %%TBD - How to do Int 15h call to get this info? */
560 bp->s.mca_info_len = 0;
561 ZeroMem(bp->s.mca_info_buf, sizeof bp->s.mca_info_buf);
564 * Pointing device presence.
567 /* %%TBD - How to do Int 11h call to get this info? */
568 bp->s.aux_dev_info = NO_MOUSE;
571 * EFI loader signature and address of EFI system table.
574 CopyMem(bp->s.efi_loader_sig, EFI_LOADER_SIG, 4);
575 bp->s.efi_sys_tbl = 0; /* %%TBD */
578 * Kernel entry point.
581 bp->s.kernel_start = (UINT32)kernel_start;
584 * When changing stuff in the parameter structure compare
585 * the offsets of the fields with the offsets used in the
586 * boot sector and setup source files.
587 * arch/i386/boot/bootsect.S
588 * arch/i386/boot/setup.S
589 * arch/i386/kernel/setup.c
592 #define CHECK_OFFSET(n, o, f) \
594 UINTN p = (UINT8 *)&bp->s.n - (UINT8 *)bp; \
595 UINTN q = (UINTN)(o); \
598 Print(L"%20a: %3xh %3xh ", #n, p, q); \
606 #define WAIT_FOR_KEY() \
609 while (ST->ConIn->ReadKeyStroke(ST->ConIn, &key) != EFI_SUCCESS) { \
617 CHECK_OFFSET(orig_cursor_col, 0x00, L"%xh");
618 CHECK_OFFSET(orig_cursor_row, 0x01, L"%xh");
619 CHECK_OFFSET(ext_mem_k, 0x02, L"%xh");
620 CHECK_OFFSET(orig_video_page, 0x04, L"%xh");
621 CHECK_OFFSET(orig_video_mode, 0x06, L"%xh");
622 CHECK_OFFSET(orig_video_cols, 0x07, L"%xh");
623 CHECK_OFFSET(orig_ega_bx, 0x0A, L"%xh");
624 CHECK_OFFSET(orig_video_rows, 0x0E, L"%xh");
625 CHECK_OFFSET(is_vga, 0x0F, L"%xh");
626 CHECK_OFFSET(orig_video_points, 0x10, L"%xh");
627 CHECK_OFFSET(lfb_width, 0x12, L"%xh");
628 CHECK_OFFSET(lfb_height, 0x14, L"%xh");
629 CHECK_OFFSET(lfb_depth, 0x16, L"%xh");
630 CHECK_OFFSET(lfb_base, 0x18, L"%xh");
631 CHECK_OFFSET(lfb_size, 0x1C, L"%xh");
632 CHECK_OFFSET(cmdline_magik, 0x20, L"%xh");
633 CHECK_OFFSET(cmdline_offset, 0x22, L"%xh");
634 CHECK_OFFSET(lfb_line_len, 0x24, L"%xh");
635 CHECK_OFFSET(lfb_red_size, 0x26, L"%xh");
636 CHECK_OFFSET(lfb_red_pos, 0x27, L"%xh");
637 CHECK_OFFSET(lfb_green_size, 0x28, L"%xh");
638 CHECK_OFFSET(lfb_green_pos, 0x29, L"%xh");
639 CHECK_OFFSET(lfb_blue_size, 0x2A, L"%xh");
640 CHECK_OFFSET(lfb_blue_pos, 0x2B, L"%xh");
641 CHECK_OFFSET(lfb_rsvd_size, 0x2C, L"%xh");
642 CHECK_OFFSET(lfb_rsvd_pos, 0x2D, L"%xh");
643 CHECK_OFFSET(vesa_seg, 0x2E, L"%xh");
644 CHECK_OFFSET(vesa_off, 0x30, L"%xh");
645 CHECK_OFFSET(lfb_pages, 0x32, L"%xh");
646 CHECK_OFFSET(lfb_reserved, 0x34, L"");
647 CHECK_OFFSET(apm_bios_ver, 0x40, L"%xh");
648 CHECK_OFFSET(bios_code_seg, 0x42, L"%xh");
649 CHECK_OFFSET(bios_entry_point, 0x44, L"%xh");
650 CHECK_OFFSET(bios_code_seg16, 0x48, L"%xh");
651 CHECK_OFFSET(bios_data_seg, 0x4A, L"%xh");
652 CHECK_OFFSET(apm_bios_flags, 0x4C, L"%xh");
653 CHECK_OFFSET(bios_code_len, 0x4E, L"%xh");
654 CHECK_OFFSET(bios_data_len, 0x52, L"%xh");
655 CHECK_OFFSET(hd0_info, 0x80, L"");
656 CHECK_OFFSET(hd1_info, 0x90, L"");
657 CHECK_OFFSET(mca_info_len, 0xA0, L"%xh");
658 CHECK_OFFSET(mca_info_buf, 0xA2, L"");
659 CHECK_OFFSET(efi_loader_sig, 0x1C0, L"'%-4.4a'");
660 CHECK_OFFSET(efi_sys_tbl, 0x1C4, L"%xh");
661 CHECK_OFFSET(efi_mem_desc_size, 0x1C8, L"%xh");
662 CHECK_OFFSET(efi_mem_desc_ver, 0x1CC, L"%xh");
663 CHECK_OFFSET(efi_mem_map, 0x1D0, L"%xh");
664 CHECK_OFFSET(efi_mem_map_size, 0x1D4, L"%xh");
665 CHECK_OFFSET(loader_start, 0x1D8, L"%xh");
666 CHECK_OFFSET(loader_size, 0x1DC, L"%xh");
667 CHECK_OFFSET(alt_mem_k, 0x1E0, L"%xh");
668 CHECK_OFFSET(setup_sectors, 0x1F1, L"%xh");
669 CHECK_OFFSET(mount_root_rdonly, 0x1F2, L"%xh");
670 CHECK_OFFSET(sys_size, 0x1F4, L"%xh");
671 CHECK_OFFSET(swap_dev, 0x1F6, L"%xh");
672 CHECK_OFFSET(ramdisk_flags, 0x1F8, L"%xh");
673 CHECK_OFFSET(video_mode_flag, 0x1FA, L"%xh");
674 CHECK_OFFSET(orig_root_dev, 0x1FC, L"%xh");
675 CHECK_OFFSET(aux_dev_info, 0x1FF, L"%xh");
676 CHECK_OFFSET(jump, 0x200, L"%xh");
677 CHECK_OFFSET(setup_sig, 0x202, L"'%-4.4a'");
678 CHECK_OFFSET(hdr_minor, 0x206, L"%xh");
679 CHECK_OFFSET(hdr_major, 0x207, L"%xh");
680 CHECK_OFFSET(rm_switch, 0x208, L"%xh");
681 CHECK_OFFSET(start_sys_seg, 0x20C, L"%xh");
682 CHECK_OFFSET(kernel_verstr_offset, 0x20E, L"%xh");
683 CHECK_OFFSET(loader_type, 0x210, L"%xh");
684 CHECK_OFFSET(loader_flags, 0x211, L"%xh");
685 CHECK_OFFSET(setup_move_size, 0x212, L"%xh");
686 CHECK_OFFSET(kernel_start, 0x214, L"%xh");
687 CHECK_OFFSET(initrd_start, 0x218, L"%xh");
688 CHECK_OFFSET(initrd_size, 0x21C, L"%xh");
689 CHECK_OFFSET(bootsect_helper, 0x220, L"%xh");
690 CHECK_OFFSET(heap_end_ptr, 0x224, L"%xh");
691 CHECK_OFFSET(base_mem_size, 0x226, L"%xh");
694 ERR_PRT((L"Boot sector and/or setup parameter alignment error."));
701 * Get video information.
702 * Do this last so that any other cursor positioning done
703 * in the fill routine gets accounted for.
706 efi_status = ST->ConOut->QueryMode(
708 ST->ConOut->Mode->Mode,
712 if (EFI_ERROR(efi_status)) {
713 ERR_PRT((L"QueryMode failed. Fake it."));
721 mode = (UINT8)ST->ConOut->Mode->Mode;
722 col = (UINT8)ST->ConOut->Mode->CursorColumn;
723 row = (UINT8)ST->ConOut->Mode->CursorRow;
726 bp->s.orig_cursor_col = col;
727 bp->s.orig_cursor_row = row;
728 bp->s.orig_video_page = 0;
729 bp->s.orig_video_mode = mode;
730 bp->s.orig_video_cols = (UINT8)cols;
731 bp->s.orig_video_rows = (UINT8)rows;
733 /* %%TBD - How to do Int 10h calls to get video info? */
734 bp->s.orig_ega_bx = 0;
736 bp->s.orig_video_points = 0;
738 /* %%TBD - How to do Int 10h calls to get frame buffer info? */
740 bp->s.lfb_height = 0;
744 bp->s.lfb_line_len = 0;
745 bp->s.lfb_red_size = 0;
746 bp->s.lfb_red_pos = 0;
747 bp->s.lfb_green_size = 0;
748 bp->s.lfb_green_pos = 0;
749 bp->s.lfb_blue_size = 0;
750 bp->s.lfb_blue_pos = 0;
751 bp->s.lfb_rsvd_size = 0;
752 bp->s.lfb_rsvd_pos = 0;
758 * Get memory map description and cookie for ExitBootServices()
761 if (get_memmap(&mdesc)) {
762 ERR_PRT((L"Could not get memory map."));
767 *cookie = mdesc.cookie;
768 bp->s.efi_mem_map = (UINTN)mdesc.md;
769 bp->s.efi_mem_map_size = mdesc.map_size;
770 bp->s.efi_mem_desc_size = mdesc.desc_size;
771 bp->s.efi_mem_desc_ver = mdesc.desc_version;
772 bp->s.efi_sys_tbl = (UINTN)systab;
775 * my_ia32_boot_params and get ready to slap them into 0x00104c00
778 efi_ia32_bp.size= sizeof(efi_ia32_bp);
779 efi_ia32_bp.command_line = (UINT32) cmdline;
780 efi_ia32_bp.efi_sys_tbl = bp->s.efi_sys_tbl;
781 efi_ia32_bp.efi_mem_map = bp->s.efi_mem_map;
782 efi_ia32_bp.efi_mem_map_size = bp->s.efi_mem_map_size;
783 efi_ia32_bp.efi_mem_desc_size = bp->s.efi_mem_desc_size;
784 efi_ia32_bp.efi_mem_desc_version = bp->s.efi_mem_desc_ver;
785 efi_ia32_bp.initrd_start = (UINTN)initrd->start_addr;
786 efi_ia32_bp.initrd_size = initrd->pgcnt * EFI_PAGE_SIZE;
787 efi_ia32_bp.loader_start = 0;
788 efi_ia32_bp.loader_size = 0;
789 efi_ia32_bp.kernel_start = bp->s.kernel_start;
790 efi_ia32_bp.kernel_size = kernel_size;
791 efi_ia32_bp.num_cols = cols;
792 efi_ia32_bp.num_rows = rows;
793 efi_ia32_bp.orig_x = col;
794 efi_ia32_bp.orig_y = row;