efi: Leave 64MiB to firmware instead of 16MiB

This commit is contained in:
mintsuki 2021-08-22 17:57:52 +02:00
parent 48f7dee672
commit 9a934eb683
2 changed files with 10 additions and 10 deletions

View File

@ -319,12 +319,12 @@ full-hybrid-test:
cp -rv bin/* test/* test_image/boot/ cp -rv bin/* test/* test_image/boot/
xorriso -as mkisofs -b boot/limine-cd.bin -no-emul-boot -boot-load-size 4 -boot-info-table --efi-boot boot/limine-eltorito-efi.bin -efi-boot-part --efi-boot-image --protective-msdos-label test_image/ -o test.iso xorriso -as mkisofs -b boot/limine-cd.bin -no-emul-boot -boot-load-size 4 -boot-info-table --efi-boot boot/limine-eltorito-efi.bin -efi-boot-part --efi-boot-image --protective-msdos-label test_image/ -o test.iso
bin/limine-install test.iso bin/limine-install test.iso
qemu-system-x86_64 -M q35 -bios ovmf-x64/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -cdrom test.iso -debugcon stdio qemu-system-x86_64 -m 512M -M q35 -bios ovmf-x64/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -cdrom test.iso -debugcon stdio
qemu-system-x86_64 -M q35 -bios ovmf-x64/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -hda test.iso -debugcon stdio qemu-system-x86_64 -m 512M -M q35 -bios ovmf-x64/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -hda test.iso -debugcon stdio
qemu-system-x86_64 -M q35 -bios ovmf-ia32/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -cdrom test.iso -debugcon stdio qemu-system-x86_64 -m 512M -M q35 -bios ovmf-ia32/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -cdrom test.iso -debugcon stdio
qemu-system-x86_64 -M q35 -bios ovmf-ia32/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -hda test.iso -debugcon stdio qemu-system-x86_64 -m 512M -M q35 -bios ovmf-ia32/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -hda test.iso -debugcon stdio
qemu-system-x86_64 -M q35 -net none -smp 4 -enable-kvm -cpu host -cdrom test.iso -debugcon stdio qemu-system-x86_64 -m 512M -M q35 -net none -smp 4 -enable-kvm -cpu host -cdrom test.iso -debugcon stdio
qemu-system-x86_64 -M q35 -net none -smp 4 -enable-kvm -cpu host -hda test.iso -debugcon stdio qemu-system-x86_64 -m 512M -M q35 -net none -smp 4 -enable-kvm -cpu host -hda test.iso -debugcon stdio
.PHONY: pxe-test .PHONY: pxe-test
pxe-test: pxe-test:
@ -357,7 +357,7 @@ uefi-test:
sudo umount test_image/ sudo umount test_image/
sudo losetup -d `cat loopback_dev` sudo losetup -d `cat loopback_dev`
rm -rf test_image loopback_dev rm -rf test_image loopback_dev
qemu-system-x86_64 -M q35 -L ovmf -bios ovmf-x64/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -hda test.hdd -debugcon stdio qemu-system-x86_64 -m 512M -M q35 -L ovmf -bios ovmf-x64/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -hda test.hdd -debugcon stdio
.PHONY: uefi32-test .PHONY: uefi32-test
uefi32-test: uefi32-test:
@ -380,4 +380,4 @@ uefi32-test:
sudo umount test_image/ sudo umount test_image/
sudo losetup -d `cat loopback_dev` sudo losetup -d `cat loopback_dev`
rm -rf test_image loopback_dev rm -rf test_image loopback_dev
qemu-system-x86_64 -M q35 -L ovmf -bios ovmf-ia32/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -hda test.hdd -debugcon stdio qemu-system-x86_64 -m 512M -M q35 -L ovmf -bios ovmf-ia32/OVMF.fd -net none -smp 4 -enable-kvm -cpu host -hda test.hdd -debugcon stdio

View File

@ -321,8 +321,8 @@ void init_memmap(void) {
allocations_disallowed = false; allocations_disallowed = false;
// Let's leave 16MiB to the firmware // Let's leave 64MiB to the firmware
ext_mem_alloc_type(0x1000000, MEMMAP_EFI_RECLAIMABLE); ext_mem_alloc_type(0x4000000, MEMMAP_EFI_RECLAIMABLE);
memcpy(untouched_memmap, memmap, memmap_entries * sizeof(struct e820_entry_t)); memcpy(untouched_memmap, memmap, memmap_entries * sizeof(struct e820_entry_t));
untouched_memmap_entries = memmap_entries; untouched_memmap_entries = memmap_entries;