[Skiboot] [PATCH] mambo: Remove reliance on env(SIMHOST)

Michael Neuling mikey at neuling.org
Thu Apr 28 13:03:21 AEST 2016


The SIMHOST environment variable is not present in all version of
mambo.  This removes the reliance on it and instead uses the "display
default_configure" command to find the simulator type.

Signed-off-by: Michael Neuling <mikey at neuling.org>
---
 external/mambo/skiboot.tcl | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/external/mambo/skiboot.tcl b/external/mambo/skiboot.tcl
index f0dc028..5c2c2ce 100644
--- a/external/mambo/skiboot.tcl
+++ b/external/mambo/skiboot.tcl
@@ -62,10 +62,8 @@ mconfig tap_base MAMBO_NET_TAP_BASE 0
 #
 # Create machine config
 #
-if { ! [info exists env(SIMHOST)] } {
-    set env(SIMHOST) "pegasus"
-}
-define dup $env(SIMHOST) myconf
+set default_config [display default_configure]
+define dup $default_config myconf
 myconf config cpus $mconf(cpus)
 myconf config processor/number_of_threads $mconf(threads)
 myconf config memory_size $mconf(memory)
@@ -81,7 +79,7 @@ myconf config machine_option/NO_RAM TRUE
 myconf config machine_option/NO_ROM TRUE
 
 # We need to be DD2 or greater on p8 for the HILE HID bit.
-if { $env(SIMHOST) == "pegasus" } {
+if { $default_config == "PEGASUS" } {
     myconf config processor/initial/PVR 0x4b0201
 }
 
-- 
2.7.4



More information about the Skiboot mailing list