ia64/xen-unstable
changeset 18826:612218519cb5
hvmloader: Relocate the etherboot ROM to be near the end of VGA
BIOS. Current Xen hard coded VGA ROM at 0xC0000 and etherboot ROM
at 0xD0000. This makes the space in [0xC0000 - 0xDFFFF] to be
fragments, which makes it hard to find enough space to hold another
Option ROM.
Signed-off-by: Shan Haitao <haitao.shan@intel.com>
BIOS. Current Xen hard coded VGA ROM at 0xC0000 and etherboot ROM
at 0xD0000. This makes the space in [0xC0000 - 0xDFFFF] to be
fragments, which makes it hard to find enough space to hold another
Option ROM.
Signed-off-by: Shan Haitao <haitao.shan@intel.com>
author | Keir Fraser <keir.fraser@citrix.com> |
---|---|
date | Mon Nov 24 11:17:44 2008 +0000 (2008-11-24) |
parents | 285f8635f573 |
children | 521d4d90f6e3 |
files | tools/firmware/hvmloader/config.h tools/firmware/hvmloader/hvmloader.c |
line diff
1.1 --- a/tools/firmware/hvmloader/config.h Mon Nov 24 11:12:20 2008 +0000 1.2 +++ b/tools/firmware/hvmloader/config.h Mon Nov 24 11:17:44 2008 +0000 1.3 @@ -23,7 +23,6 @@ 1.4 /* Memory map. */ 1.5 #define HYPERCALL_PHYSICAL_ADDRESS 0x00080000 1.6 #define VGABIOS_PHYSICAL_ADDRESS 0x000C0000 1.7 -#define ETHERBOOT_PHYSICAL_ADDRESS 0x000D0000 1.8 #define SMBIOS_PHYSICAL_ADDRESS 0x000E9000 1.9 #define SMBIOS_MAXIMUM_SIZE 0x00001000 1.10 #define ACPI_PHYSICAL_ADDRESS 0x000EA000
2.1 --- a/tools/firmware/hvmloader/hvmloader.c Mon Nov 24 11:12:20 2008 +0000 2.2 +++ b/tools/firmware/hvmloader/hvmloader.c Mon Nov 24 11:17:44 2008 +0000 2.3 @@ -462,7 +462,7 @@ static uint16_t init_xen_platform_io_bas 2.4 int main(void) 2.5 { 2.6 int vgabios_sz = 0, etherboot_sz = 0, rombios_sz, smbios_sz; 2.7 - uint32_t vga_ram = 0; 2.8 + uint32_t etherboot_phys_addr, vga_ram = 0; 2.9 uint16_t xen_pfiob; 2.10 2.11 printf("HVM Loader\n"); 2.12 @@ -516,7 +516,10 @@ int main(void) 2.13 printf("VGA RAM at %08x\n", vga_ram); 2.14 } 2.15 2.16 - etherboot_sz = scan_etherboot_nic((void*)ETHERBOOT_PHYSICAL_ADDRESS); 2.17 + /* Ethernet ROM is placed after VGA ROM, on next 2kB boundary. */ 2.18 + etherboot_phys_addr = 2.19 + (VGABIOS_PHYSICAL_ADDRESS + vgabios_sz + 2047) & ~2047; 2.20 + etherboot_sz = scan_etherboot_nic((void *)etherboot_phys_addr); 2.21 2.22 if ( get_acpi_enabled() ) 2.23 { 2.24 @@ -533,8 +536,8 @@ int main(void) 2.25 VGABIOS_PHYSICAL_ADDRESS + vgabios_sz - 1); 2.26 if ( etherboot_sz ) 2.27 printf(" %05x-%05x: Etherboot ROM\n", 2.28 - ETHERBOOT_PHYSICAL_ADDRESS, 2.29 - ETHERBOOT_PHYSICAL_ADDRESS + etherboot_sz - 1); 2.30 + etherboot_phys_addr, 2.31 + etherboot_phys_addr + etherboot_sz - 1); 2.32 if ( smbios_sz ) 2.33 printf(" %05x-%05x: SMBIOS tables\n", 2.34 SMBIOS_PHYSICAL_ADDRESS,