changeset e9edb137c872 in /z/repo/m5
details: http://repo.m5sim.org/m5?cmd=changeset;node=e9edb137c872
description:
X86: Change how the default disk image gets set up.
The disk image to use was always being forced to a particular value.
This
change changes what disk image is selected as the default based on the
architecture being built. In the future, a more sophisticated system
might be
used that selected a path based on certain rules instead of relying on
one off
file names.
diffstat:
configs/common/Benchmarks.py | 9 ++++++++-
configs/common/FSConfig.py | 1 -
2 files changed, 8 insertions(+), 2 deletions(-)
diffs (38 lines):
diff -r 6029008db669 -r e9edb137c872 configs/common/Benchmarks.py
--- a/configs/common/Benchmarks.py Tue Feb 01 18:28:41 2011 -0800
+++ b/configs/common/Benchmarks.py Wed Feb 02 18:03:58 2011 -0800
@@ -27,6 +27,7 @@
# Authors: Ali Saidi
from SysPaths import *
+from m5.defines import buildEnv
class SysConfig:
def __init__(self, script=None, mem=None, disk=None):
@@ -49,8 +50,14 @@
def disk(self):
if self.diskname:
return disk(self.diskname)
+ elif buildEnv['TARGET_ISA'] == 'alpha':
+ return env.get('LINUX_IMAGE', disk('linux-latest.img'))
+ elif buildEnv['TARGET_ISA'] == 'x86':
+ return env.get('LINUX_IMAGE', disk('x86root.img'))
else:
- return env.get('LINUX_IMAGE', disk('linux-latest.img'))
+ print "Don't know what default disk image to use for ISA %s" % \
+ buildEnv['TARGET_ISA']
+ sys.exit(1)
# Benchmarks are defined as a key in a dict which is a list of SysConfigs
# The first defined machine is the test system, the others are driving systems
diff -r 6029008db669 -r e9edb137c872 configs/common/FSConfig.py
--- a/configs/common/FSConfig.py Tue Feb 01 18:28:41 2011 -0800
+++ b/configs/common/FSConfig.py Wed Feb 02 18:03:58 2011 -0800
@@ -293,7 +293,6 @@
if not mdesc:
# generic system
mdesc = SysConfig()
- mdesc.diskname = 'x86root.img'
self.readfile = mdesc.script()
self.mem_mode = mem_mode
_______________________________________________
m5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/m5-dev