summaryrefslogtreecommitdiff
path: root/src/mainboard
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard')
-rw-r--r--src/mainboard/intel/cougar_canyon2/romstage.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mainboard/intel/cougar_canyon2/romstage.c b/src/mainboard/intel/cougar_canyon2/romstage.c
index 998528dc4f..bf5b738754 100644
--- a/src/mainboard/intel/cougar_canyon2/romstage.c
+++ b/src/mainboard/intel/cougar_canyon2/romstage.c
@@ -298,7 +298,9 @@ void romstage_main_continue(EFI_STATUS status, VOID *HobListPtr) {
}
/* Save the HOB pointer in CBMEM to be used in ramstage. */
- cbmem_hob_ptr = cbmem_add (CBMEM_ID_HOB_POINTER, sizeof(*HobListPtr));
+ cbmem_hob_ptr = cbmem_add(CBMEM_ID_HOB_POINTER, sizeof(*HobListPtr));
+ if (cbmem_hob_ptr == NULL)
+ die("Could not allocate cbmem for HOB pointer");
*(u32*)cbmem_hob_ptr = (u32)HobListPtr;
post_code(0x4f);