configs, arch-arm: don't search for default DTB and kernel
authorCiro Santilli <ciro.santilli@arm.com>
Mon, 3 Dec 2018 17:03:41 +0000 (17:03 +0000)
committerCiro Santilli <ciro.santilli@arm.com>
Fri, 25 Jan 2019 13:06:16 +0000 (13:06 +0000)
Before this commit, there were default magic DTB and kernel filenames
for some platforms.

This was inelegant and error prone, as it refered to out-of-tree files,
and set defaults which users almost always want to customize with
explicit command line options.

One result of this is that a wrong exception could be thrown if --kernel
was given but not --machine-type, since the default machine type
VExpress_EMM had a default kernel, and the code would always search for
the default filename even though --kernel was given:

IOError: Can't find file 'vmlinux.aarch32.ll_20131205.0-gem5' on path.

The defaults existed only for older machine types, and not for the
usually recommended VExpress_GEM5_V1, which suggests that this
deprecation should not affect many users.

Change-Id: Ia49298304f658701ea0800bd79e08db404a655c3
Reviewed-on: https://gem5-review.googlesource.com/c/15898
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Jason Lowe-Power <jason@lowepower.com>

configs/common/FSConfig.py

index e4babbcb6c8a069a1a41d6f1d25cf06c97a2cb63..e8cd0083bc48a06c0874e5c7051536ea97517003 100644 (file)
@@ -210,18 +210,6 @@ def makeArmSystem(mem_mode, machine_type, num_cpus=1, mdesc=None,
                   ignore_dtb=False):
     assert machine_type
 
-    default_dtbs = {
-        "RealViewPBX": None,
-        "VExpress_EMM": "vexpress.aarch32.ll_20131205.0-gem5.%dcpu.dtb" % num_cpus,
-        "VExpress_EMM64": "vexpress.aarch64.20140821.dtb",
-    }
-
-    default_kernels = {
-        "RealViewPBX": "vmlinux.arm.smp.fb.2.6.38.8",
-        "VExpress_EMM": "vmlinux.aarch32.ll_20131205.0-gem5",
-        "VExpress_EMM64": "vmlinux.aarch64.20140821",
-    }
-
     pci_devices = []
 
     if bare_metal:
@@ -251,11 +239,8 @@ def makeArmSystem(mem_mode, machine_type, num_cpus=1, mdesc=None,
     self.realview = platform_class()
 
     if not dtb_filename and not (bare_metal or ignore_dtb):
-        try:
-            dtb_filename = default_dtbs[machine_type]
-        except KeyError:
-            fatal("No DTB specified and no default DTB known for '%s'" % \
-                  machine_type)
+        fatal("No DTB specified and no default DTB known for '%s'" % \
+                machine_type)
 
     if isinstance(self.realview, VExpress_EMM64):
         if os.path.split(mdesc.disk())[-1] == 'linux-aarch32-ael.img':
@@ -304,9 +289,6 @@ def makeArmSystem(mem_mode, machine_type, num_cpus=1, mdesc=None,
         # EOT character on UART will end the simulation
         self.realview.uart[0].end_on_eot = True
     else:
-        if machine_type in default_kernels:
-            self.kernel = binary(default_kernels[machine_type])
-
         if dtb_filename and not ignore_dtb:
             self.dtb_filename = binary(dtb_filename)