diff --git a/src/hello/hello.d b/src/hello/hello.d index e8d68f3..cd389ac 100644 --- a/src/hello/hello.d +++ b/src/hello/hello.d @@ -4,6 +4,7 @@ import scratch; import hulk.bootinfo; import hos.page_table; import hos.cpu; +import hos.memory; __gshared EFI_SYSTEM_TABLE * st; __gshared BootInfo bootinfo; @@ -124,7 +125,9 @@ private bool get_memory_map() private PageTableEntry * new_page_table() { - return cast(PageTableEntry *)scratch_alloc(1u); + PageTableEntry * pt = cast(PageTableEntry *)scratch_alloc(1u); + memset64(pt, 0u, 512); + return pt; } private void map(ulong source_page, ulong dest_page, PageTableEntry * pt_base)