2002-07-25 18:49:29 +04:00
|
|
|
/*
|
2002-07-09 16:24:59 +04:00
|
|
|
** Copyright 2001-2002, Travis Geiselbrecht. All rights reserved.
|
|
|
|
** Distributed under the terms of the NewOS License.
|
|
|
|
*/
|
|
|
|
#ifndef _KERNEL_MEMHEAP_H
|
|
|
|
#define _KERNEL_MEMHEAP_H
|
|
|
|
|
2004-10-18 19:23:34 +04:00
|
|
|
#include <OS.h>
|
2003-05-03 20:03:26 +04:00
|
|
|
|
|
|
|
struct kernel_args;
|
2002-07-09 16:24:59 +04:00
|
|
|
|
2002-07-25 18:49:29 +04:00
|
|
|
#define HEAP_SIZE 0x00400000
|
2002-08-05 21:22:19 +04:00
|
|
|
// 4 MB heap for the kernel
|
|
|
|
|
2002-07-25 18:49:29 +04:00
|
|
|
|
2004-10-18 19:23:34 +04:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
|
|
|
void *memalign(size_t alignment, size_t size);
|
|
|
|
|
|
|
|
status_t heap_init(addr_t heapBase);
|
2004-10-23 17:50:27 +04:00
|
|
|
status_t heap_init_post_sem(struct kernel_args *args);
|
|
|
|
status_t heap_init_post_thread(struct kernel_args *args);
|
2004-10-18 19:23:34 +04:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
2002-07-09 16:24:59 +04:00
|
|
|
|
2002-10-30 02:03:47 +03:00
|
|
|
#endif /* _KERNEL_MEMHEAP_H */
|