qemu-e2k/hw/i386
Li Zhijian aab50e5344 i386: allow to load initrd below 4 GB for recent linux
Since linux commit: cf8fa920cb42 ("i386: handle an initrd in highmem (version 2)")
linux has supported initrd up to 4 GB, but the header field
ramdisk_max is still set to 2 GB to avoid "possible bootloader bugs".

When use '-kernel vmlinux -initrd initrd.cgz' to launch a VM,
the firmware(it could be linuxboot_dma.bin) helps to read initrd
contents into guest memory(below ramdisk_max) and jump to kernel.
that's similar with what bootloader does, like grub.

In addition, initrd_max is uint32_t simply because QEMU doesn't support
the 64-bit boot protocol (specifically the ext_ramdisk_image field).

Therefore here just limit initrd_max to UINT32_MAX simply as well to
allow initrd to be loaded below 4 GB.

NOTE: it's possible that linux protocol within [0x208, 0x20c]
supports up to 4 GB initrd as well.

CC: Paolo Bonzini <pbonzini@redhat.com>
CC: Richard Henderson <rth@twiddle.net>
CC: Eduardo Habkost <ehabkost@redhat.com>
CC: "Michael S. Tsirkin" <mst@redhat.com>
CC: Marcel Apfelbaum <marcel.apfelbaum@gmail.com>
Signed-off-by: Li Zhijian <lizhijian@cn.fujitsu.com>

Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
2019-02-05 16:50:18 +01:00
..
kvm ioapic: use TYPE_FOO MACRO than constant string 2019-01-09 11:33:47 +01:00
xen xen: introduce new 'XenBus' and 'XenDevice' object hierarchy 2019-01-14 13:45:40 +00:00
acpi-build.c typo: apci->acpi 2019-01-30 10:16:58 +01:00
acpi-build.h
amd_iommu.c x86-iommu: switch intr_supported to OnOffAuto type 2018-12-20 13:25:11 -05:00
amd_iommu.h
intel_iommu_internal.h
intel_iommu.c x86-iommu: switch intr_supported to OnOffAuto type 2018-12-20 13:25:11 -05:00
kvmvapic.c
Makefile.objs
multiboot.c elf: Add optional function ptr to load_elf() to parse ELF notes 2019-02-05 16:50:16 +01:00
multiboot.h
pc_piix.c hw/i386/pc: enable PVH only for machine type >= 4.0 2019-02-05 16:50:17 +01:00
pc_q35.c hw/i386/pc: enable PVH only for machine type >= 4.0 2019-02-05 16:50:17 +01:00
pc_sysfw.c
pc.c i386: allow to load initrd below 4 GB for recent linux 2019-02-05 16:50:18 +01:00
trace-events
vmmouse.c
vmport.c
x86-iommu.c x86-iommu: turn on IR by default if proper 2018-12-20 13:25:11 -05:00