summaryrefslogtreecommitdiffstats
path: root/src/core/heap.c
blob: 4afd270b12419d575580c0b62122c379f3a05022 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include <gpxe/malloc.h>
#include <gpxe/heap.h>

/**
 * @file
 *
 * Heap
 *
 */

/**
 * Heap size
 *
 * Currently fixed at 48kB.
 */
#define HEAP_SIZE ( 48 * 1024 )

/** The heap itself */
char heap[HEAP_SIZE] __attribute__ (( aligned ( __alignof__(void *) )));

/**
 * Initialise the heap
 *
 */
void init_heap ( void ) {
	mpopulate ( heap, sizeof ( heap ) );
}