summaryrefslogtreecommitdiff
path: root/configs/common
diff options
context:
space:
mode:
authorAli Saidi <Ali.Saidi@ARM.com>2011-04-04 11:42:31 -0500
committerAli Saidi <Ali.Saidi@ARM.com>2011-04-04 11:42:31 -0500
commitd6289507d875dede9201bb2c48a889eca1e19900 (patch)
tree514f6d4382afb96f551eb21d15874aba95fa79ef /configs/common
parent332adcdd1a11301a229f7c70a40f6ffd1270b3bf (diff)
downloadgem5-d6289507d875dede9201bb2c48a889eca1e19900.tar.xz
ARM: Include IDE/CF controller by default in PBX model.
Frame buffer and boot linux: ./build/ARM_FS/m5.opt configs/example/fs.py --benchmark=ArmLinuxFrameBuf --kernel=vmlinux.touchkit Linux from a CF card: ./build/ARM_FS/m5.opt configs/example/fs.py --benchmark=ArmLinuxCflash --kernel=vmlinux.touchkit Run Android ./build/ARM_FS/m5.opt configs/example/fs.py --benchmark=ArmAndroid --kernel=vmlinux.android Run MP ./build/ARM_FS/m5.opt configs/example/fs.py --benchmark=ArmLinuxCflash --kernel=vmlinux.mp-2.6.38
Diffstat (limited to 'configs/common')
-rw-r--r--configs/common/Benchmarks.py9
-rw-r--r--configs/common/FSConfig.py47
2 files changed, 34 insertions, 22 deletions
diff --git a/configs/common/Benchmarks.py b/configs/common/Benchmarks.py
index 366152d62..608dba266 100644
--- a/configs/common/Benchmarks.py
+++ b/configs/common/Benchmarks.py
@@ -55,6 +55,8 @@ class SysConfig:
return env.get('LINUX_IMAGE', disk('linux-latest.img'))
elif buildEnv['TARGET_ISA'] == 'x86':
return env.get('LINUX_IMAGE', disk('x86root.img'))
+ elif buildEnv['TARGET_ISA'] == 'arm':
+ return env.get('LINUX_IMAGE', disk('ael-arm.ext2'))
else:
print "Don't know what default disk image to use for ISA %s" % \
buildEnv['TARGET_ISA']
@@ -109,9 +111,10 @@ Benchmarks = {
'ValStreamCopy': [SysConfig('micro_streamcopy.rcS', '512MB')],
'MutexTest': [SysConfig('mutex-test.rcS', '128MB')],
-
- 'bnAn': [SysConfig('/z/saidi/work/m5.newmem.head/configs/boot/bn-app.rcS',
- '128MB', '/z/saidi/work/bottleneck/bnimg.img')]
+ 'ArmLinux': [SysConfig('null.rcS', '128MB', 'ael-arm.ext2')],
+ 'ArmLinuxFrameBuf': [SysConfig('null.rcS', '128MB', 'ael-full.ext2')],
+ 'ArmLinuxCflash': [SysConfig('null.rcS', '256MB', 'linux-arm.img')],
+ 'ArmAndroid': [SysConfig('null.rcS', '256MB', 'android-mbr.img')],
}
benchs = Benchmarks.keys()
diff --git a/configs/common/FSConfig.py b/configs/common/FSConfig.py
index 48ece0db4..8ab06a5d0 100644
--- a/configs/common/FSConfig.py
+++ b/configs/common/FSConfig.py
@@ -206,16 +206,6 @@ def makeArmSystem(mem_mode, machine_type, mdesc = None, bare_metal=False):
self.mem_mode = mem_mode
- #self.cf0 = CowIdeDisk(driveID='master')
- #self.cf0.childImage(mdesc.disk())
- #self.cf_ctrl = IdeController(disks=[self.cf0],
- # pci_func = 0, pci_dev = 0, pci_bus = 0,
- # io_shift = 1, ctrl_offset = 2, Command = 0x1,
- # BAR0 = 0x18000000, BAR0Size = '16B',
- # BAR1 = 0x18000100, BAR1Size = '1B',
- # BAR0LegacyIO = True, BAR1LegacyIO = True,)
- #self.cf_ctrl.pio = self.iobus.port
-
if machine_type == "RealView_PBX":
self.realview = RealViewPBX()
elif machine_type == "RealView_EB":
@@ -224,20 +214,39 @@ def makeArmSystem(mem_mode, machine_type, mdesc = None, bare_metal=False):
print "Unknown Machine Type"
sys.exit(1)
+ use_cf = False
+ if mdesc.disk()[-4:] == ".img":
+ use_cf = True
+ self.cf0 = CowIdeDisk(driveID='master')
+ self.cf0.childImage(mdesc.disk())
+ self.realview.cf_ctrl.disks = [self.cf0]
+
if bare_metal:
# EOT character on UART will end the simulation
self.realview.uart.end_on_eot = True
- self.physmem = PhysicalMemory(range = AddrRange(Addr('256MB')), zero = True)
+ self.physmem = PhysicalMemory(range = AddrRange(Addr('256MB')),
+ zero = True)
else:
- self.physmem = PhysicalMemory(range = AddrRange(Addr('128MB')), zero = True)
- self.diskmem = PhysicalMemory(range = AddrRange(Addr('128MB'), size = '128MB'),
- file = disk('ael-arm.ext2'))
- self.diskmem.port = self.membus.port
- self.machine_type = machine_type
self.kernel = binary('vmlinux.arm')
- self.boot_osflags = 'earlyprintk mem=128MB console=ttyAMA0' + \
- ' lpj=19988480 norandmaps slram=slram0,0x8000000,+0x8000000' + \
- ' mtdparts=slram0:- rw loglevel=8 root=/dev/mtdblock0'
+ self.machine_type = machine_type
+ boot_flags = 'earlyprintk console=ttyAMA0 lpj=19988480 norandmaps ' + \
+ 'rw loglevel=8 '
+ if use_cf:
+ self.physmem = PhysicalMemory(range = AddrRange(Addr('256MB')),
+ zero = True)
+ boot_flags += "mem=256MB root=/dev/sda1 "
+ else:
+ self.physmem = PhysicalMemory(range = AddrRange(Addr('128MB')),
+ zero = True)
+ self.diskmem = PhysicalMemory(range = AddrRange(Addr('128MB'),
+ size = '128MB'),
+ file = disk(mdesc.disk()))
+ self.diskmem.port = self.membus.port
+ boot_flags += "mem=128MB slram=slram0,0x8000000,+0x8000000 " + \
+ "mtdparts=slram0:- root=/dev/mtdblock0 "
+ if mdesc.disk().count('android'):
+ boot_flags += "init=/init "
+ self.boot_osflags = boot_flags
self.physmem.port = self.membus.port
self.realview.attachOnChipIO(self.membus)