mirror of
https://github.com/ipxe/ipxe
synced 2025-12-19 19:49:45 +03:00
Merged mcb30-realmode-redesign back to HEAD
This commit is contained in:
@@ -1,8 +1,12 @@
|
||||
#include "etherboot.h"
|
||||
#include "init.h"
|
||||
#include "memsizes.h"
|
||||
|
||||
size_t heap_ptr, heap_top, heap_bot;
|
||||
|
||||
void init_heap(void)
|
||||
#define _virt_start 0
|
||||
|
||||
static void init_heap(void)
|
||||
{
|
||||
size_t size;
|
||||
size_t start, end;
|
||||
@@ -82,6 +86,11 @@ void init_heap(void)
|
||||
heap_ptr = heap_bot;
|
||||
}
|
||||
|
||||
static void reset_heap(void)
|
||||
{
|
||||
heap_ptr = heap_bot;
|
||||
}
|
||||
|
||||
void *allot(size_t size)
|
||||
{
|
||||
void *ptr;
|
||||
@@ -166,3 +175,5 @@ void forget2(void *ptr)
|
||||
}
|
||||
heap_ptr = addr;
|
||||
}
|
||||
|
||||
INIT_FN ( INIT_HEAP, init_heap, reset_heap, NULL );
|
||||
|
||||
Reference in New Issue
Block a user