From 9ecc5a02f253942347970a3777cb2f829c2a4804 Mon Sep 17 00:00:00 2001 From: Anouk Van Laer Date: Fri, 23 Dec 2016 10:45:55 +0000 Subject: [PATCH] gem5: Added an if-statement in board configuration, to allow for the setup of a gem5 platform This needs to be combined with changes in devlib (commit 9b41c47 in github.com/avanlaer/devlib) The changes required in lisa might changes, if the implemention of the gem5 platform in devlib would change. Changes to be committed: modified: libs/utils/env.py --- libs/utils/env.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/libs/utils/env.py b/libs/utils/env.py index bed90ee7d..f8ac2c95c 100644 --- a/libs/utils/env.py +++ b/libs/utils/env.py @@ -379,6 +379,14 @@ class TestEnv(ShareState): platform = Platform(model='MT8173') self.__modules = ['bl', 'cpufreq'] + # Initialize gem5 simulation as a board + elif self.conf['board'].upper() == 'GEM5': + platform = devlib.platform.gem5.Gem5SimulationPlatform(name='gem5', + gem5_bin=self.conf['gem5_bin'], + gem5_args=self.conf['gem5_args'], + gem5_virtio=self.conf['gem5_virtio'], + host_output_dir=self.conf['host_output_dir'], + gem5_telnet_port=self.conf['gem5_telnet_port'] if 'gem5_telnet_port' in self.conf else None) elif self.conf['board'] != 'UNKNOWN': # Initilize from platform descriptor (if available) board = self._load_board(self.conf['board']) @@ -860,7 +868,6 @@ class TestEnv(ShareState): self._log.warning('Using pre-installed DTB') else: self.tftp_deploy(tc['dtb']) - else: raise ValueError('Kernel installation method not supported') -- GitLab