| 1 |
|
| 2 |
#include <AGESA.h> |
| 3 |
#include <AMD.h> |
| 4 |
#include <heapManager.h> |
| 5 |
|
| 6 |
#include "debug_util.h" |
| 7 |
|
| 8 |
static const char undefined[] = "undefined"; |
| 9 |
|
| 10 |
static const char *HeapStatusStr[] = { |
| 11 |
"DoNotExistYet", "LocalCache", "TempMem", "SystemMem", "DoNotExistAnymore","S3Resume" |
| 12 |
}; |
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
const char *heap_status_name(UINT8 HeapStatus) |
| 18 |
{ |
| 19 |
if ((HeapStatus < HEAP_DO_NOT_EXIST_YET) || (HeapStatus > HEAP_S3_RESUME)) |
| 20 |
return undefined; |
| 21 |
|
| 22 |
int index = HeapStatus - HEAP_DO_NOT_EXIST_YET; |
| 23 |
return HeapStatusStr[index]; |
| 24 |
} |