thermosphere: implement reading and writing guest memory

This commit is contained in:
TuxSH
2020-01-20 02:24:02 +00:00
parent 0f0228e240
commit 217c1ad054
22 changed files with 467 additions and 118 deletions

View File

@@ -26,6 +26,6 @@ void devicesMapAllExtra(void)
// Don't broadcast, since it's only ran once per boot by only one core, before the others are started...
__tlb_invalidate_el2_local();
__dsb();
__dsb_local();
__isb();
}

View File

@@ -39,18 +39,18 @@ void stage2ConfigureAndEnable(void)
// Stage2 regs config
SET_SYSREG(vttbr_el2, vttbr);
SET_SYSREG(vtcr_el2, vtcr);
__dsb();
__dsb_local();
__isb();
// Enable stage 2
u64 hcr = GET_SYSREG(hcr_el2);
hcr |= HCR_VM;
SET_SYSREG(hcr_el2, hcr);
__dsb();
__dsb_local();
__isb();
// TLB invalidation
__tlb_invalidate_el1_stage12_local();
__dsb();
__dsb_local();
__isb();
}

View File

@@ -33,6 +33,6 @@ void devicesMapAllExtra(void)
// Don't broadcast, since it's only ran once per boot by only one core, before the others are started...
__tlb_invalidate_el2_local();
__dsb();
__dsb_local();
__isb();
}