Make the ski loader functional again after the previous set of changes.
This commit is contained in:
parent
f79d4144ab
commit
66ddefc574
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=220283
@ -223,39 +223,37 @@ ResetSystem(enum efi_reset type, efi_status status, u_long datasz,
|
||||
void
|
||||
efi_stub_init(struct bootinfo *bi)
|
||||
{
|
||||
struct efi_md *memp;
|
||||
static struct efi_md memmap[4];
|
||||
|
||||
/* Describe the SKI memory map. */
|
||||
bi->bi_memmap = (u_int64_t)(bi + 1);
|
||||
bi->bi_memmap_size = 4 * sizeof(struct efi_md);
|
||||
bi->bi_memmap = (uintptr_t)(void *)memmap;
|
||||
bi->bi_memmap_size = sizeof(memmap);
|
||||
bi->bi_memdesc_size = sizeof(struct efi_md);
|
||||
bi->bi_memdesc_version = 1;
|
||||
|
||||
memp = (struct efi_md *)bi->bi_memmap;
|
||||
memmap[0].md_type = EFI_MD_TYPE_PALCODE;
|
||||
memmap[0].md_phys = 0x100000;
|
||||
memmap[0].md_virt = NULL;
|
||||
memmap[0].md_pages = (1L*1024*1024)>>12;
|
||||
memmap[0].md_attr = EFI_MD_ATTR_WB | EFI_MD_ATTR_RT;
|
||||
|
||||
memp[0].md_type = EFI_MD_TYPE_PALCODE;
|
||||
memp[0].md_phys = 0x100000;
|
||||
memp[0].md_virt = NULL;
|
||||
memp[0].md_pages = (4L*1024*1024)>>12;
|
||||
memp[0].md_attr = EFI_MD_ATTR_WB | EFI_MD_ATTR_RT;
|
||||
memmap[1].md_type = EFI_MD_TYPE_FREE;
|
||||
memmap[1].md_phys = 4L*1024*1024;
|
||||
memmap[1].md_virt = NULL;
|
||||
memmap[1].md_pages = (128L*1024*1024)>>12;
|
||||
memmap[1].md_attr = EFI_MD_ATTR_WB;
|
||||
|
||||
memp[1].md_type = EFI_MD_TYPE_FREE;
|
||||
memp[1].md_phys = 5L*1024*1024;
|
||||
memp[1].md_virt = NULL;
|
||||
memp[1].md_pages = (128L*1024*1024)>>12;
|
||||
memp[1].md_attr = EFI_MD_ATTR_WB;
|
||||
memmap[2].md_type = EFI_MD_TYPE_FREE;
|
||||
memmap[2].md_phys = 4L*1024*1024*1024;
|
||||
memmap[2].md_virt = NULL;
|
||||
memmap[2].md_pages = (64L*1024*1024)>>12;
|
||||
memmap[2].md_attr = EFI_MD_ATTR_WB;
|
||||
|
||||
memp[2].md_type = EFI_MD_TYPE_FREE;
|
||||
memp[2].md_phys = 4L*1024*1024*1024;
|
||||
memp[2].md_virt = NULL;
|
||||
memp[2].md_pages = (64L*1024*1024)>>12;
|
||||
memp[2].md_attr = EFI_MD_ATTR_WB;
|
||||
|
||||
memp[3].md_type = EFI_MD_TYPE_IOPORT;
|
||||
memp[3].md_phys = 0xffffc000000;
|
||||
memp[3].md_virt = NULL;
|
||||
memp[3].md_pages = (64L*1024*1024)>>12;
|
||||
memp[3].md_attr = EFI_MD_ATTR_UC;
|
||||
memmap[3].md_type = EFI_MD_TYPE_IOPORT;
|
||||
memmap[3].md_phys = 0xffffc000000;
|
||||
memmap[3].md_virt = NULL;
|
||||
memmap[3].md_pages = (64L*1024*1024)>>12;
|
||||
memmap[3].md_attr = EFI_MD_ATTR_UC;
|
||||
|
||||
bi->bi_systab = (u_int64_t)&efi_systab;
|
||||
}
|
||||
|
@ -43,9 +43,9 @@ ia64_platform_alloc(vm_offset_t va, vm_size_t sz __unused)
|
||||
vm_paddr_t pa;
|
||||
|
||||
if (va == 0)
|
||||
pa = 1024 * 1024;
|
||||
pa = 2 * 1024 * 1024;
|
||||
else
|
||||
pa = (va - IA64_PBVM_BASE) + (64 * 1024 * 1024);
|
||||
pa = (va - IA64_PBVM_BASE) + (32 * 1024 * 1024);
|
||||
|
||||
return (pa);
|
||||
}
|
||||
@ -65,7 +65,9 @@ ia64_platform_bootinfo(struct bootinfo *bi, struct bootinfo **res)
|
||||
sal_stub_init();
|
||||
acpi_stub_init();
|
||||
|
||||
*res = &bootinfo;
|
||||
if (IS_LEGACY_KERNEL())
|
||||
*res = &bootinfo;
|
||||
|
||||
return (0);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user