From: BitKeeper B. <ri...@su...> - 2005-02-25 15:09:33
|
ChangeSet 1.1242, 2005/02/23 18:15:50-08:00, aru...@in... [PATCH] Setup EFI memory descriptors for I/O Ports Signed-off-by: Arun Sharma <aru...@in...> dom_fw.c | 28 ++++++++++++++-------------- 1 files changed, 14 insertions(+), 14 deletions(-) diff -Nru a/xen/arch/ia64/dom_fw.c b/xen/arch/ia64/dom_fw.c --- a/xen/arch/ia64/dom_fw.c 2005-02-24 05:02:00 -05:00 +++ b/xen/arch/ia64/dom_fw.c 2005-02-24 05:02:00 -05:00 @@ -319,12 +319,12 @@ unsigned long maxmem = d->max_pages * PAGE_SIZE; unsigned long start_mpaddr = ((d==dom0)?dom0_start:0); -# define MAKE_MD(typ, attr, start, end) \ +# define MAKE_MD(typ, attr, start, end, abs) \ do { \ md = efi_memmap + i++; \ md->type = typ; \ md->pad = 0; \ - md->phys_addr = start_mpaddr + start; \ + md->phys_addr = abs ? start : start_mpaddr + start; \ md->virt_addr = 0; \ md->num_pages = (end - start) >> 12; \ md->attribute = attr; \ @@ -472,27 +472,27 @@ /* simulate 1MB free memory at physical address zero */ i = 0; - MAKE_MD(EFI_BOOT_SERVICES_DATA,EFI_MEMORY_WB,0*MB,1*MB); + MAKE_MD(EFI_BOOT_SERVICES_DATA,EFI_MEMORY_WB,0*MB,1*MB, 0); /* hypercall patches live here, masquerade as reserved PAL memory */ - MAKE_MD(EFI_PAL_CODE,EFI_MEMORY_WB,HYPERCALL_START,HYPERCALL_END); - MAKE_MD(EFI_CONVENTIONAL_MEMORY,EFI_MEMORY_WB,HYPERCALL_END,maxmem); + MAKE_MD(EFI_PAL_CODE,EFI_MEMORY_WB,HYPERCALL_START,HYPERCALL_END, 0); + MAKE_MD(EFI_CONVENTIONAL_MEMORY,EFI_MEMORY_WB,HYPERCALL_END,maxmem, 0); #ifdef PASS_THRU_IOPORT_SPACE if (d == dom0 && !running_on_sim) { /* pass through the I/O port space */ - efi_memory_desc_t efi_get_io_md(void); - efi_memory_desc_t ia64_efi_io_md = efi_get_io_md(); + efi_memory_desc_t *efi_get_io_md(void); + efi_memory_desc_t *ia64_efi_io_md = efi_get_io_md(); u32 type; u64 iostart, ioend, ioattr; - type = ia64_efi_io_md.type; - iostart = ia64_efi_io_md.phys_addr; - ioend = ia64_efi_io_md.phys_addr + - (ia64_efi_io_md.num_pages << 12); - ioattr = ia64_efi_io_md.attribute; - MAKE_MD(type,ioattr,iostart,ioend); + type = ia64_efi_io_md->type; + iostart = ia64_efi_io_md->phys_addr; + ioend = ia64_efi_io_md->phys_addr + + (ia64_efi_io_md->num_pages << 12); + ioattr = ia64_efi_io_md->attribute; + MAKE_MD(type,ioattr,iostart,ioend, 1); } else - MAKE_MD(EFI_RESERVED_TYPE,0,0,0); + MAKE_MD(EFI_RESERVED_TYPE,0,0,0,0); #endif bp->efi_systab = dom_pa(fw_mem); |