aboutsummaryrefslogtreecommitdiff
path: root/src/lib/coreboot_table.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/coreboot_table.c')
-rw-r--r--src/lib/coreboot_table.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/lib/coreboot_table.c b/src/lib/coreboot_table.c
index 365283fffe..332bed172a 100644
--- a/src/lib/coreboot_table.c
+++ b/src/lib/coreboot_table.c
@@ -227,6 +227,19 @@ static void lb_board_id(struct lb_header *header)
#endif
}
+static void lb_ram_code(struct lb_header *header)
+{
+#if IS_ENABLED(CONFIG_RAM_CODE_SUPPORT)
+ struct lb_ram_code *code;
+
+ code = (struct lb_ram_code *)lb_new_record(header);
+
+ code->tag = LB_TAG_RAM_CODE;
+ code->size = sizeof(*code);
+ code->ram_code = ram_code();
+#endif
+}
+
static void add_cbmem_pointers(struct lb_header *header)
{
/*
@@ -452,6 +465,9 @@ unsigned long write_coreboot_table(
/* Add board ID if available */
lb_board_id(head);
+ /* Add RAM config if available */
+ lb_ram_code(head);
+
add_cbmem_pointers(head);
/* Add board-specific table entries, if any. */