summaryrefslogtreecommitdiffstats
path: root/sys/boot/efi/libefi
diff options
context:
space:
mode:
authormarcel <marcel@FreeBSD.org>2011-03-16 03:53:18 +0000
committermarcel <marcel@FreeBSD.org>2011-03-16 03:53:18 +0000
commit8e0b0a22844d3d1383011c024b1eb1a3b2ee51a8 (patch)
tree55215f77e655236a449e347f8f98d98dfb718eed /sys/boot/efi/libefi
parente79931d6175d1a1999786ee313a144784de8d6a9 (diff)
downloadFreeBSD-src-8e0b0a22844d3d1383011c024b1eb1a3b2ee51a8.zip
FreeBSD-src-8e0b0a22844d3d1383011c024b1eb1a3b2ee51a8.tar.gz
MFaltix:
Add support for Pre-Boot Virtual Memory (PBVM) to the loader. PBVM allows us to link the kernel at a fixed virtual address without having to make any assumptions about the physical memory layout. On the SGI Altix 350 for example, there's no usuable physical memory below 192GB. Also, the PBVM allows us to control better where we're going to physically load the kernel and its modules so that we can make sure we load the kernel in memory that's close to the BSP. The PBVM is managed by a simple page table. The minimum size of the page table is 4KB (EFI page size) and the maximum is currently set to 1MB. A page in the PBVM is 64KB, as that's the maximum alignment one can specify in a linker script. The bottom line is that PBVM is between 64KB and 8GB in size. The loader maps the PBVM page table at a fixed virtual address and using a single translations. The PBVM itself is also mapped using a single translation for a maximum of 32MB. While here, increase the heap in the EFI loader from 512KB to 2MB and set the stage for supporting relocatable modules.
Diffstat (limited to 'sys/boot/efi/libefi')
-rw-r--r--sys/boot/efi/libefi/libefi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/boot/efi/libefi/libefi.c b/sys/boot/efi/libefi/libefi.c
index 20ea48c..9e921f3 100644
--- a/sys/boot/efi/libefi/libefi.c
+++ b/sys/boot/efi/libefi/libefi.c
@@ -92,7 +92,7 @@ efi_main(EFI_HANDLE image_handle, EFI_SYSTEM_TABLE *system_table)
BS = ST->BootServices;
RS = ST->RuntimeServices;
- heapsize = 512*1024;
+ heapsize = 2 * 1024 * 1024;
status = BS->AllocatePages(AllocateAnyPages, EfiLoaderData,
EFI_SIZE_TO_PAGES(heapsize), &heap);
if (status != EFI_SUCCESS)
OpenPOWER on IntegriCloud