From 6f88fa17bc847c903f3e4d89000a9585f99ac100 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ciro=20Santilli=20=E5=85=AD=E5=9B=9B=E4=BA=8B=E4=BB=B6=20?= =?UTF-8?q?=E6=B3=95=E8=BD=AE=E5=8A=9F?= Date: Wed, 21 Aug 2019 00:00:00 +0000 Subject: [PATCH] gem5: minimally test VExpress_GEM5_V2 --- README.adoc | 15 +++++++++++++++ build-gem5 | 1 + common.py | 8 ++++++-- shell_helpers.py | 5 +++++ 4 files changed, 27 insertions(+), 2 deletions(-) diff --git a/README.adoc b/README.adoc index adc79b6..5bba950 100644 --- a/README.adoc +++ b/README.adoc @@ -1328,6 +1328,8 @@ The reason for that is that on baremetal we don't parse the <> +* `VExpress_GEM5_V2`: VExpress_GEM5_V1 with GICv3, uses a different bootloader `arm/aarch64_bootloader/boot_emm_v2.arm64` TODO is it because of GICv3? +* anything that does not start with: `VExpress_GEM5_`: old and bad, don't use them + === gem5 internals ==== gem5 Python C++ interaction diff --git a/build-gem5 b/build-gem5 index 968a4a7..fb12689 100755 --- a/build-gem5 +++ b/build-gem5 @@ -110,6 +110,7 @@ https://github.com/cirosantilli/linux-kernel-module-cheat-regression#gem5-unit-t # TODO cross_compile is ignored because the make does not use CC... self.sh.run_cmd(['make', '-C', bootloader64_dir, LF]) self.sh.cp(os.path.join(bootloader64_dir, 'boot_emm.arm64'), binaries_dir) + self.sh.cp(os.path.join(bootloader64_dir, 'boot_emm_v2.arm64'), binaries_dir) term_source_dir = os.path.join(self.env['gem5_source_dir'], 'util/term') m5term_build = os.path.join(term_source_dir, 'm5term') self.sh.run_cmd(['make', '-C', term_source_dir, LF]) diff --git a/common.py b/common.py index 5a56904..3f20404 100644 --- a/common.py +++ b/common.py @@ -459,8 +459,12 @@ Which qemu binaries to use: qemu-system-, qemu-, qemu-img, etc.: '--machine', help='''\ Machine type: -* QEMU default: virt -* gem5 default: VExpress_GEM5_V1 + +* QEMU default: -machine virt +* gem5 default: --machine-type VExpress_GEM5_V1 + +More infor on platforms at: +https://cirosantilli.com/linux-kernel-module-cheat#gem5-arm-platforms ''' ) diff --git a/shell_helpers.py b/shell_helpers.py index af1c836..55ed3b7 100644 --- a/shell_helpers.py +++ b/shell_helpers.py @@ -215,6 +215,11 @@ class ShellHelpers: else: shutil.copy2(src, dest) + def mv(self, src, dest, **kwargs): + self.print_cmd(['mv', src, dest]) + if not self.dry_run: + shutil.move(src, dest) + def print_cmd( self, cmd,