[SeaBIOS] [PATCH] run qemu_cfg_e820 only for CONFIG_QEMU=y

Gerd Hoffmann kraxel at redhat.com
Fri Dec 6 13:28:12 CET 2013


Otherwise we'll clobber the e820 table from coreboot.

Signed-off-by: Gerd Hoffmann <kraxel at redhat.com>
---
 src/fw/paravirt.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/fw/paravirt.c b/src/fw/paravirt.c
index b84196a..00e327d 100644
--- a/src/fw/paravirt.c
+++ b/src/fw/paravirt.c
@@ -253,6 +253,9 @@ qemu_cfg_e820(void)
     struct e820_reservation *table;
     int i, size;
 
+    if (!CONFIG_QEMU)
+        return;
+
     // "etc/e820" has both ram and reservations
     table = romfile_loadfile("etc/e820", &size);
     if (table) {
-- 
1.8.3.1




More information about the SeaBIOS mailing list