[coreboot-gerrit] New patch to review for coreboot: emulation/qemu-i440fx qemu-q35: Asmlinkage for romstage main()

Kyösti Mälkki (kyosti.malkki@gmail.com) gerrit at coreboot.org
Fri Jun 17 20:18:51 CEST 2016


Kyösti Mälkki (kyosti.malkki at gmail.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/15226

-gerrit

commit 08b4902b1a787a2d731d4c0a80e5eca71e8236ae
Author: Kyösti Mälkki <kyosti.malkki at gmail.com>
Date:   Fri Jun 17 10:35:29 2016 +0300

    emulation/qemu-i440fx qemu-q35: Asmlinkage for romstage main()
    
    Change-Id: I66238525c5c4d97313a589373144741f1be97483
    Signed-off-by: Kyösti Mälkki <kyosti.malkki at gmail.com>
---
 src/mainboard/emulation/qemu-i440fx/cache_as_ram.inc | 2 +-
 src/mainboard/emulation/qemu-i440fx/romstage.c       | 6 ++++--
 src/mainboard/emulation/qemu-q35/romstage.c          | 6 ++++--
 3 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/src/mainboard/emulation/qemu-i440fx/cache_as_ram.inc b/src/mainboard/emulation/qemu-i440fx/cache_as_ram.inc
index 7349af8..297eaf1 100644
--- a/src/mainboard/emulation/qemu-i440fx/cache_as_ram.inc
+++ b/src/mainboard/emulation/qemu-i440fx/cache_as_ram.inc
@@ -49,7 +49,7 @@ cache_as_ram:
 before_romstage:
 	post_code(0x29)
 	/* Call romstage.c main function. */
-	call	main
+	call	romstage_main
 
 	post_code(0x30)
 
diff --git a/src/mainboard/emulation/qemu-i440fx/romstage.c b/src/mainboard/emulation/qemu-i440fx/romstage.c
index d03c8ab..bc23929 100644
--- a/src/mainboard/emulation/qemu-i440fx/romstage.c
+++ b/src/mainboard/emulation/qemu-i440fx/romstage.c
@@ -21,14 +21,14 @@
 #include <pc80/mc146818rtc.h>
 #include <console/console.h>
 #include <cpu/x86/bist.h>
+#include <cpu/intel/romstage.h>
 #include <timestamp.h>
 #include <delay.h>
 #include <cpu/x86/lapic.h>
 
 #include "memory.c"
 
-#include <cpu/intel/romstage.h>
-void main(unsigned long bist)
+void * asmlinkage romstage_main(unsigned long bist)
 {
 	int cbmem_was_initted;
 
@@ -48,4 +48,6 @@ void main(unsigned long bist)
 	timestamp_init(timestamp_get());
 	timestamp_add_now(TS_START_ROMSTAGE);
 
+	/* Emulation uses fixed low stack during ramstage. */
+	return NULL;
 }
diff --git a/src/mainboard/emulation/qemu-q35/romstage.c b/src/mainboard/emulation/qemu-q35/romstage.c
index fb0bccf..1bb51da 100644
--- a/src/mainboard/emulation/qemu-q35/romstage.c
+++ b/src/mainboard/emulation/qemu-q35/romstage.c
@@ -22,14 +22,14 @@
 #include <console/console.h>
 #include <southbridge/intel/i82801ix/i82801ix.h>
 #include <cpu/x86/bist.h>
+#include <cpu/intel/romstage.h>
 #include <timestamp.h>
 #include <delay.h>
 #include <cpu/x86/lapic.h>
 
 #include "../qemu-i440fx/memory.c"
 
-#include <cpu/intel/romstage.h>
-void main(unsigned long bist)
+void * asmlinkage romstage_main(unsigned long bist)
 {
 	int cbmem_was_initted;
 
@@ -50,4 +50,6 @@ void main(unsigned long bist)
 	timestamp_init(timestamp_get());
 	timestamp_add_now(TS_START_ROMSTAGE);
 
+	/* Emulation uses fixed low stack during ramstage. */
+	return NULL;
 }



More information about the coreboot-gerrit mailing list