diff options
| author | Patrick Williams <iawillia@us.ibm.com> | 2010-05-21 16:03:32 -0500 |
|---|---|---|
| committer | Patrick Williams <iawillia@us.ibm.com> | 2010-05-21 16:03:32 -0500 |
| commit | a0e3bdeaed824af328e0bafc59e69ebfd1b3de4e (patch) | |
| tree | 469c99443aface768c7b70a018d34409cec432d8 /src/include/kernel | |
| parent | 343cc75d83b7d71a23adb49e0d530eb59997a154 (diff) | |
| download | talos-hostboot-a0e3bdeaed824af328e0bafc59e69ebfd1b3de4e.tar.gz talos-hostboot-a0e3bdeaed824af328e0bafc59e69ebfd1b3de4e.zip | |
malloc / free support
Diffstat (limited to 'src/include/kernel')
| -rw-r--r-- | src/include/kernel/heapmgr.H | 4 | ||||
| -rw-r--r-- | src/include/kernel/pagemgr.H | 2 |
2 files changed, 6 insertions, 0 deletions
diff --git a/src/include/kernel/heapmgr.H b/src/include/kernel/heapmgr.H index 41a3e2cf5..6e189da93 100644 --- a/src/include/kernel/heapmgr.H +++ b/src/include/kernel/heapmgr.H @@ -7,12 +7,16 @@ class HeapManager { public: + static void init(); + static void* allocate(size_t n); static void free(void *); enum { BUCKETS = 8, + + MAX_ALLOC_SIZE = (1 << (BUCKETS + 4)) - 8, }; protected: diff --git a/src/include/kernel/pagemgr.H b/src/include/kernel/pagemgr.H index b99cedff2..fded2c6c1 100644 --- a/src/include/kernel/pagemgr.H +++ b/src/include/kernel/pagemgr.H @@ -11,6 +11,8 @@ class PageManager { public: + static void init(); + static void* allocatePage(size_t n = 1); static void freePage(void*, size_t n = 1); |

