mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-06-14 17:58:59 +00:00
hv: vm_load: set zeropage just past boot args
Which should in Linux guest gpa, not in hypervisor HVA. Tracked-On: #1124 Signed-off-by: Li, Fei1 <fei1.li@intel.com>
This commit is contained in:
parent
9368373fd9
commit
49b476bb56
@ -47,8 +47,9 @@ static uint64_t create_zero_page(struct vm *vm)
|
||||
uint64_t gpa, addr;
|
||||
|
||||
/* Set zeropage in Linux Guest RAM region just past boot args */
|
||||
hva = gpa2hva(vm, (uint64_t)sw_linux->bootargs_load_addr);
|
||||
zeropage = (struct zero_page *)((char *)hva + MEM_4K);
|
||||
gpa = (uint64_t)sw_linux->bootargs_load_addr + MEM_4K;
|
||||
hva = gpa2hva(vm, gpa);
|
||||
zeropage = hva;
|
||||
|
||||
/* clear the zeropage */
|
||||
(void)memset(zeropage, 0U, MEM_2K);
|
||||
@ -78,9 +79,6 @@ static uint64_t create_zero_page(struct vm *vm)
|
||||
/* Create/add e820 table entries in zeropage */
|
||||
zeropage->e820_nentries = (uint8_t)create_e820_table(zeropage->e820);
|
||||
|
||||
/* Get the host physical address of the zeropage */
|
||||
gpa = hpa2gpa(vm, hva2hpa((void *)zeropage));
|
||||
|
||||
/* Return Physical Base Address of zeropage */
|
||||
return gpa;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user