Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

heap.c 358B

123456789101112131415161718192021222324252627
  1. #include <malloc.h>
  2. #include <gpxe/heap.h>
  3. /**
  4. * @file
  5. *
  6. * Heap
  7. *
  8. */
  9. /**
  10. * Heap size
  11. *
  12. * Currently fixed at 48kB.
  13. */
  14. #define HEAP_SIZE ( 48 * 1024 )
  15. /** The heap itself */
  16. char heap[HEAP_SIZE] __attribute__ (( aligned ( __alignof__(void *) )));
  17. /**
  18. * Initialise the heap
  19. *
  20. */
  21. void init_heap ( void ) {
  22. mpopulate ( heap, sizeof ( heap ) );
  23. }