diff options
author | Alexis211 <alexis211@gmail.com> | 2009-10-26 14:56:28 +0100 |
---|---|---|
committer | Alexis211 <alexis211@gmail.com> | 2009-10-26 14:56:28 +0100 |
commit | 4cab9cdad95aba4934b22872c94e44fab759250c (patch) | |
tree | b45cf1ba9b196c41b7580ded72a8cbc6a6fd7764 /Source/Kernel/MemoryManager | |
parent | d68a064819deaaa8e01eca3c7809050b25cedfbd (diff) | |
download | Melon-4cab9cdad95aba4934b22872c94e44fab759250c.tar.gz Melon-4cab9cdad95aba4934b22872c94e44fab759250c.zip |
Some changes...
Diffstat (limited to 'Source/Kernel/MemoryManager')
-rw-r--r-- | Source/Kernel/MemoryManager/Mem.ns.cpp | 8 | ||||
-rw-r--r-- | Source/Kernel/MemoryManager/Mem.ns.h | 6 |
2 files changed, 7 insertions, 7 deletions
diff --git a/Source/Kernel/MemoryManager/Mem.ns.cpp b/Source/Kernel/MemoryManager/Mem.ns.cpp index 144b9f3..a0809b0 100644 --- a/Source/Kernel/MemoryManager/Mem.ns.cpp +++ b/Source/Kernel/MemoryManager/Mem.ns.cpp @@ -6,12 +6,12 @@ namespace Mem { bool pagingEnabled = false; -u32int placementAddress; +size_t placementAddress; Heap kheap; //Placement malloc, used while heap is not initialized -void *kallocInternal(u32int sz, bool align) { +void *kallocInternal(size_t sz, bool align) { if (kheap.usable()) return 0; if (align && (placementAddress & 0xFFFFF000)) { placementAddress &= 0xFFFFF000; @@ -40,7 +40,7 @@ void createHeap() { kheap.create(heapStart, heapSize, heapIndexSize, kernelPageDirectory, false, false); } -void *alloc(u32int sz, bool align) { +void *alloc(size_t sz, bool align) { if (!kheap.usable()) return kallocInternal(sz, align); if (align) return 0; @@ -51,7 +51,7 @@ void free(void *ptr) { kheap.free(ptr); } -void* mkXchgSpace(u32int sz) { +void* mkXchgSpace(size_t sz) { return Task::currThread()->mkXchgSpace(sz); } diff --git a/Source/Kernel/MemoryManager/Mem.ns.h b/Source/Kernel/MemoryManager/Mem.ns.h index b06ab79..f6094cc 100644 --- a/Source/Kernel/MemoryManager/Mem.ns.h +++ b/Source/Kernel/MemoryManager/Mem.ns.h @@ -5,13 +5,13 @@ namespace Mem { extern bool pagingEnabled; - extern u32int placementAddress; + extern size_t placementAddress; void createHeap(); - void *alloc(u32int sz, bool align = false); + void *alloc(size_t sz, bool align = false); void free(void *ptr); - void* mkXchgSpace(u32int sz); //This creates a space between userland and kernel land where data can be exchanged + void* mkXchgSpace(size_t sz); //This creates a space between userland and kernel land where data can be exchanged u32int kheapSize(), kheapFree(); } |