mirror of
https://github.com/justinian/jsix.git
synced 2025-12-10 08:24:32 -08:00
[kernel] Move more from kutil to kernel
The moving of kernel-only code out of kutil continues. (See 042f061)
This commit moves the following:
- The heap allocator code
- memory.cpp/h which means:
- letting string.h be the right header for memset and memcpy, still
including an implementation of it for the kernel though, since
we're not linking libc to the kernel
- Changing calls to kalloc/kfree to new/delete in kutil containers
that aren't going to be merged into the kernel
- Fixing a problem with stdalign.h from libc, which was causing issues
for type_traits.
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
#include <string.h>
|
||||
|
||||
#include "kutil/assert.h"
|
||||
#include "kutil/memory.h"
|
||||
|
||||
#include "frame_allocator.h"
|
||||
#include "kernel_memory.h"
|
||||
#include "page_tree.h"
|
||||
@@ -33,7 +35,7 @@ page_tree::page_tree(uint64_t base, uint8_t level) :
|
||||
m_base {base & level_mask(level)},
|
||||
m_level {level}
|
||||
{
|
||||
kutil::memset(m_entries, 0, sizeof(m_entries));
|
||||
memset(m_entries, 0, sizeof(m_entries));
|
||||
}
|
||||
|
||||
page_tree::~page_tree()
|
||||
|
||||
Reference in New Issue
Block a user