diff --git a/scripts/layoutrom.py b/scripts/layoutrom.py
index dd770fe..04e7efa 100755
--- a/scripts/layoutrom.py
+++ b/scripts/layoutrom.py
@@ -646,9 +646,10 @@ def main():
         entrysym = symbols['16'].get('entry_csm')
     else:
         entrysym = symbols['16'].get('reset_vector')
+    mb_section = symbols['32flat'].get('mb_head').section
     anchorsections = [entrysym.section] + [
         section for section in allsections
-        if section.name.startswith('.fixedaddr.')]
+        if section.name.startswith('.fixedaddr.')] + [mb_section]
     keepsections = findReachable(anchorsections, checkKeep, symbols)
     sections = [section for section in allsections if section in keepsections]
 
diff --git a/src/fw/coreboot.c b/src/fw/coreboot.c
index 8fd8449..6610b3a 100644
--- a/src/fw/coreboot.c
+++ b/src/fw/coreboot.c
@@ -551,3 +551,19 @@ cbfs_payload_setup(void)
         boot_add_cbfs(cfile->fhdr, desc, bootprio_find_named_rom(filename, 0));
     }
 }
+
+void VARLOW
+mb_head(u32 mbptr)
+{
+  asm volatile(
+	".align 4\n"
+	"mb_header:\n"
+	".long 0x1BADB002\n"
+	".long 0x00010000\n"
+	".long -(0x1BADB002+0x00010000)\n"
+	".long mb_header\n"
+	".long _reloc_abs_start\n"
+	".long 0\n"
+	".long 0\n"
+	".long entry_elf\n");
+}
_______________________________________________
SeaBIOS mailing list
[email protected]
http://www.seabios.org/mailman/listinfo/seabios

Reply via email to